Search found 1570 matches

by kersing
Wed Feb 13, 2013 9:47 pm
Forum: Flowcode V5 Free Edition
Topic: How to implement "else if" in Decision
Replies: 7
Views: 11674

Re: How to implement "else if" in Decision

That is not what I was trying to tell you at all. Question for you: How would you code the following in C? (Flowcode equivalent will be provided after you've answered :-) ) if i between 20 and 30 call subroutineA else if i between 40 and 50, add 150 to i else if i between 100 and 200, subtract 100 f...
by kersing
Tue Feb 12, 2013 11:41 pm
Forum: Flowcode V5
Topic: Working with interrupts.
Replies: 6
Views: 4004

Re: Working with interrupts.

Looking at the generated C code I see you have a macro Sense_PortB which switches the Port B pins to input just after you have switched them to output and made them high for the pin change function. Also you test the pin status in that macro, but it is only called at the start of the program, not in...
by kersing
Tue Feb 12, 2013 12:14 am
Forum: Flowcode V5
Topic: Working with interrupts.
Replies: 6
Views: 4004

Re: Working with interrupts.

Generally it is not a good idea to delay for significant amounts of time in interrupt routines. You want them to be handled as soon as possible to avoid missing the next interrupt. For testing purposes I would remove the clear/print waiting sequence from the main loop. Also in the interrupt, clear s...
by kersing
Mon Feb 11, 2013 6:53 pm
Forum: Flowcode V5
Topic: Working with interrupts.
Replies: 6
Views: 4004

Re: Working with interrupts.

I do not have the AVR version of Flowcode so I haven't opened your program, but do you print "Waiting" continuously in the loop? If so, would it not overwrite the "Got it" message the ISR displays before you get a chance to read that message?
by kersing
Mon Feb 11, 2013 6:48 pm
Forum: Flowcode V5
Topic: External ADC to 18F2553 via SPI
Replies: 2
Views: 2121

Re: External ADC to 18F2553 via SPI

The SPI component macro's SPI_Get_Char reads one 8 bit byte. SPI_Get_String reads the specified number of bytes and stores them in a String. The names of the macros can be confusing as they could be interpreted to return ASCII characters/strings but they do return byte(s). To read an integer value (...
by kersing
Sun Feb 10, 2013 10:35 pm
Forum: General Programming
Topic: Digital signal to binary
Replies: 1
Views: 1638

Re: Digital signal to binary

I have moved your question to the general programming area as it is not a tip or trick (please do not post questions in that forum). Please register for the forum appropriate for your version of Flowcode so one of the moderators can move this topic there. (registration instructions for Flowcode 5 or...
by kersing
Sat Feb 09, 2013 1:44 pm
Forum: Flowcode V5
Topic: RS232 Interupts
Replies: 15
Views: 10593

Re: RS232 Interupts

This processor has 2 EUART modules. This results in two sets of bits to enable/disable/check the interrupts.

For UART1 change RCIE to RC1IE and RCIF to RC1IF.
For UART2 change RCIE to RC2IE, pie1 to pie3, RCIF to RC2IF and pir1 to pir3.
by kersing
Thu Feb 07, 2013 11:34 pm
Forum: Flowcode V2 & V3
Topic: USB not working in flowcode v3
Replies: 3
Views: 10862

Re: USB not working in flowcode v3

You need to include a call to the component macro "Initialise_Serial" in your flow to make sure Flowcode includes all required code fragments. Once you add this the error will disappear. (Calling any of the component macros will probably work, however you will need to initialize the component anyway...
by kersing
Wed Feb 06, 2013 11:42 pm
Forum: Flowcode V5
Topic: dsPIC33 - RS232 Module + Peripherial Pin Select
Replies: 2
Views: 2225

Re: dsPIC33 - RS232 Module + Peripherial Pin Select

You will need to add a C-code block to your program (before using the RS232 macro's). If you want to set UART1 RX to pin RP97 and UART1 TX to pin RP80 use: RPINR18bits.U1RXR = 0b1001111; RPOR4bits.RP80R = 0b000001; To find this, for the input side, locate the function you want to configure (UART1 RX...
by kersing
Wed Feb 06, 2013 11:11 pm
Forum: Flowcode V4
Topic: USB Host in version 5 ?
Replies: 1
Views: 2631

Re: USB Host in version 5 ?

Flowcode 5 does not provide USB host. All supplied USB components are slave mode only. I do not expect USB host will be added soon.
by kersing
Wed Feb 06, 2013 9:09 pm
Forum: Bugs / Application Errors
Topic: I have not received the email to download the software Flowc
Replies: 18
Views: 16363

Re: I have not received the email to download the software F

Could you try changing the options to

Code: Select all

-P%p -F"%f.hex" -E -M
by kersing
Wed Feb 06, 2013 8:26 pm
Forum: Bugs / Application Errors
Topic: I have not received the email to download the software Flowc
Replies: 18
Views: 16363

Re: I have not received the email to download the software F

For use with pickit you should not use filenames with spaces. Please save your project as count.fcf and try again.
by kersing
Tue Feb 05, 2013 8:34 am
Forum: Flowcode V4
Topic: My "DSP system"- Edit Component why different?
Replies: 5
Views: 4166

Re: My "DSP system"- Edit Component why different?

DPI stands for Dots Per Inch. It is a setting of your display. For instructions on how to change this setting in windows 7/8: visit this site Set to 100% for best results with Flowcode.
by kersing
Sun Feb 03, 2013 11:31 am
Forum: Flowcode V5 Free Edition
Topic: getting outputs from sensor into PIC16F690 LCD
Replies: 7
Views: 5704

Re: getting outputs from sensor into PIC16F690 LCD

To read measurements from analog sensors, use ADC component.
by kersing
Sun Feb 03, 2013 11:29 am
Forum: Flowcode V5 Free Edition
Topic: How to implement "else if" in Decision
Replies: 7
Views: 11674

Re: How to implement "else if" in Decision

Switch can only be used for single values, not ranges, just like the C equivalent. Multiple decision blocks can be nested, that is basically what you do in C as well if ( condition ) { code1; } else if ( condition2 ) { code2; } Is equivalent to adding two decision blocks, with code1 in the "yes" flo...
by kersing
Sat Feb 02, 2013 12:49 am
Forum: E-blocks
Topic: EB006 kit with a PIC16F877A
Replies: 18
Views: 13217

Re: EB006 kit with a PIC16F877A

Could you try to compile and load the attached flowchart?
by kersing
Thu Jan 31, 2013 7:59 am
Forum: General Programming
Topic: Pickit 3 ICSP
Replies: 10
Views: 7011

Re: Pickit 3 ICSP

The first thing I notice is the capacitor on MCLR. One of the precautions:
"Do not use capacitors on MCLR: they will prevent fast transitions of VPP."

However is the combination is working with MPLAB it should be able to work with Flowcode. Could you post the messages?
by kersing
Thu Jan 31, 2013 12:26 am
Forum: General Programming
Topic: Pickit 3 ICSP
Replies: 10
Views: 7011

Re: Pickit 3 ICSP

I am using PICkit2 for in circuit programming a lot (from MPLAB) so I know how the power on these programmers works. I am unclear on the way you use the diode in your hardware. Do you have a circuit diagram? Reading your first message I get the impression PICkit3 can program your circuit using MPLAB...
by kersing
Thu Jan 31, 2013 12:03 am
Forum: General Programming
Topic: Pickit 3 ICSP
Replies: 10
Views: 7011

Re: Pickit 3 ICSP

PICkit3 is powered by USB, not the target power, except for the Input/Output drivers. What diode are you using and how is it connected? Does the same hardware (PICkit3 and target board) work correctly with MPLAB?
by kersing
Wed Jan 30, 2013 11:48 pm
Forum: E-blocks
Topic: EB006 kit with a PIC16F877A
Replies: 18
Views: 13217

Re: EB006 kit with a PIC16F877A

Please attach the output to a message. It allows us to see all the messages generated. (Output is in a file ...msg.txt in the directory your Flowcode source is stored in)
by kersing
Wed Jan 30, 2013 11:34 pm
Forum: General Programming
Topic: Pickit 3 ICSP
Replies: 10
Views: 7011

Re: Pickit 3 ICSP

Have you checked the precautions listed in PICkit3 quicksheet. It states where not to put capacitors.

Also, in MPLAB there are settings to use targer power or provide power (and what voltage) to the target. Have you set the command line switches accordingly?
by kersing
Wed Jan 30, 2013 1:18 am
Forum: E-blocks
Topic: EB006 kit with a PIC16F877A
Replies: 18
Views: 13217

Re: Welcome to the E-blocks forum

Have you checked the 16f877 is the only chip fitted? There should not be another chip in the two sockets next to the 40 pin socket. Usually there is a 16f88 in the 18 pin socket...
by kersing
Tue Jan 29, 2013 12:06 am
Forum: E-blocks
Topic: programming pic microcontroller
Replies: 22
Views: 13571

Re: programming pic microcontroller

medelec35 wrote: crystal (and caps) should be connected to pins 13 & 14 (osc1 & osc2)
Not 16 & 17!
Why oh why didn't I notice this...

Glad you did Martin :-)
by kersing
Tue Jan 29, 2013 12:02 am
Forum: General Programming
Topic: Direct Drive of Relay Board ?
Replies: 8
Views: 4096

Re: Direct Drive of Relay Board ?

Check this site for a possible solution. Or google 'drive relay from microcontroller' for more results...
by kersing
Mon Jan 28, 2013 11:15 pm
Forum: E-blocks
Topic: programming pic microcontroller
Replies: 22
Views: 13571

Re: programming pic microcontroller

Using the same 5V source for all 5V references in your circuit is fine.

Could you post your flowcode file so we can check the chip settings?