Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Hello_World
05-07-2016, 07:28 PM,
#1
Hello_World
Hello,

I am using a PIC32MX440F256H (PIC32-PINGUINO-OTG) and I am working on Windows 10 and on x4-rev999 for IDE.
I compiled and uploaded "Hello_World" on the board but I can't see the result.
I followed these different steps like this : http://wiki.pinguino.cc/index.php/Basics

First of all, I can't do the step 1 because my PC doesn't recognize the Pinguino device ( a driver problem I think).

So, I don't know how to do for the step 4 : "Select Menu->Pinguino->Debug Mode->USB CDC And on the bottom section the port x on which the device is connected and there you go". Indeed, I can't find debug mode on the IDE.

What is strange is that I can compile other programs which work well as "Blinking_led_example" : https://www.olimex.com/Products/Duino/PI...xample.zip
[url=https://www.olimex.com/Products/Duino/PIC32/_resources/PIC32-PINGUINO_blinking_led_example.zip][/url]
If someone could help me, it will be great.
Reply
06-07-2016, 08:59 AM,
#2
RE: Hello_World
Hello ! Bonjour ! Demat !
With Windows 10 and X.4 IDE I successfully tried your example HelloWorld found on the Pinguino wiki.
First the debug mode exists no more.
Secondly the MCHPCDC driver is to install.
Thirdly just after uploading look for the created port into the device panel > Ports (COM et LPT) > USB Serial Port COM #. In my case # equals 8.
Then open a terminal, create a connexion with COM # as port, 8 bits, no parity, 1stop, no stream control. As speed 115200 but it is not actually used. As soon as the connection runs the message is continuously got.

In a previous reply I indicated the MS HID driver had to be replaced by  the libusb driver. This is not necessary for X4 IDE.

Kenavo
André
Reply
06-07-2016, 10:36 AM,
#3
RE: Hello_World
Hello ! Demat !

I just tried what u told me and it works.
As you said, I looked for the created port into the device panel > Ports (COM et LPT) > USB Serial Port COM #. In my case # equals 5
So, I launched Putty terminal (in serial, COM5, speed : 115200) and I got "Hello World !!!"

I think it will be great to update this page if there isn't debug mode anymore : http://wiki.pinguino.cc/index.php/Basics
[url=http://wiki.pinguino.cc/index.php/Basics][/url]

Thank you ! Kenavo !


Attached Files Thumbnail(s)
   
Reply
06-07-2016, 11:53 AM,
#4
RE: Hello_World
Now, I am trying another program in order to read the data of air quality sensor module : http://www.sainsmart.com/sainsmart-mq135...duino.html

I think I made the right connections as on this video : https://www.youtube.com/watch?v=edkBTtp_gRg

It means : G pin on Ground (Power Con 1), V pin on 5V (Power Con 1) and AO pin on AO (Analog Con 2)

I compiled the program, I uploaded it but I can't find the created port into the device panel. It seems that it is never detected.

Here is the program I used : AnalogReadSerial

void setup() {
  Serial.begin(9600);
}

void loop() {
  int sensorValue = analogRead(A0);
  Serial.println(sensorValue, DEC);
}


Attached Files Thumbnail(s)
       
Reply
06-07-2016, 12:22 PM, (This post was last modified: 06-07-2016, 12:29 PM by gtcbreizh.)
#5
Smile  RE: Hello_World
You should replace Serial by CDC [Image: smile.gif]
Furthermore I verify the option/parameter DEC is available. If I donot send a new message it is OK.

I got an error when compiling your CDC.println(sensorValue, DEC);

You can use :
CDC.printf("%d \r\n", sensorValue);

Kenavo
André
Reply
06-07-2016, 01:01 PM,
#6
RE: Hello_World
Yes, you are right, I had to replace by CDC.printf("%d \r\n", sensorValue);
And now it works, I knew that I should use CDC instead of Serial ^^
I send in attachment what I got on Putty.

Kenavo Smile


Attached Files Thumbnail(s)
   
Reply
02-02-2017, 07:00 PM,
#7
RE: Hello_World
Hello,

I am using PIC32 pinguino OTG too but with V11 IDE in windows 7. I can't get "hello world" because Hterm (terminal) can't open com port (with some driver i can get a virtual port and other no virtual port found just see "CDC RS232 emulation demo in device manager). I tried several version of usb lib driver but no way. 
Is there somebody success to run CDC com port with V11 IDE ?

Thank

Vincent


Attached Files Thumbnail(s)
   
Reply
02-02-2017, 11:04 PM,
#8
RE: Hello_World
zadig.exe might help

John
Reply
06-02-2017, 12:33 PM,
#9
RE: Hello_World
Hello,
It's runing now!
zadig.exe didn't tested.
unfortunatly I can't explain what I did , and how the board is see as a virtual com port now.
Altrough that:Terminal (I use Hterm) com port speed has to be set to 19200 bd.
Is it possible to change the board com port speed?

Vincent
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)