Component not registered

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 4.
To post in this forum you must have a registered copy of Flowcode 4 or higher. To sign up for this forum topic please use the "Online Resources" link in the Flowcode Help Menu.

Moderator: Benj

Post Reply
kdoney34711
Posts: 25
Joined: Tue Sep 29, 2009 1:07 pm
Has thanked: 1 time

Component not registered

Post by kdoney34711 »

When I bring up some of the examples in my upgraded Flowcode 4 I get an error which says the component is not registered and then crashes flowcode. How do I register the example components?

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

Examples from v2 of Flowcode and some of the early v3 examples might show this problem.

Which examples are you trying? Please post them here and I'll take a look.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

I have the same problem. The component example TCP/IP- firewall,ARP,REC_HTML,SEND_HTML and UDP all give me that error. I'm working with a Olimex PIC-P67J60. It has the TCP-IP stack already programmed. I want to monitor 4 inputs and control 4 outputs from the web. Using the embedded server, I'm not sure of the necessary programming in Flowcode needed with the TCP/IP component when using the webserver. Does someone have an Flowcode example where you control and monitor from the webpage on the embedded server? Is the TCP stack rewritten if I have the component in my Flowcode program?
Thanks again for any help.

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

Can you please post the link for those example files so I can check them and see why this error is occuring.

Also note that the TCP/IP component in Flowcode is designed to work with the TCP/IP E-Block, which has its own hardware TCP/IP stack. It is not designed to work with any other TCP/IP stacks, so it is unlikley to work with your board.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

Steve,
Thanks for getting back with me. The files were downloaded from the Flowcode V4 example files on this site. Do you have an example I ask about using your stack? I understand that it is different then my board. Is the webserver a part of the TCP stack? I was thinking it was different .But I believe that with an example, I will still get out of it what I need. I hope to be able to use Flowcode for most of the project and program the rest in C. Which I hope will save me a lot of time. I am a newbie using the embedded webserver and I'm trying to fill in the holes.
Thanks again.
Lee

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

In our learning centre there is a course about TCP/IP which you will find useful.

The Webserver component in Flowcode uses the same hardware TCP/IP stack as the TCP/IP component, but is designed for a microcontroller to publish webpages on the Internet. The TCP/IP component is much mroe flexible and allows you to communicate using various layers of the TCP/IP stack (e.g. MAC, UDP, IP, TCP).

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

So Flowcode bypasses the on chip server/TCP to use the Eblock? If the chip came with it, why wouldn't the program be written to support it? So is there an example using the EBlock? Also, did you find the files you needed to look at the component error problem?

Thanks again,
Lee

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: Component not registered

Post by Benj »

Hi Lee

All the examples for the TCP and Webserver components are available from the Learning Centre on our website.
If the chip came with it, why wouldn't the program be written to support it?
We decided to create the TCP/IP E-Block as it allows you to create a webpage or host ethernet comms from any PICmicro device with an onboard I2C bus. You do not have to get the E-Block and could simply connect up the same Wiznet module as used on the E-Block. The E-Block just makes things much easier.

Rewriting the Ethernet components to interface with a internal or alternative module would be a huge amount of work for very little reward.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

The TCP examples don't work with my v4.2. Steve is looking into it. I'm hoping that the examples will give me what I need.

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

The examples load and compile fine on my v4. Is the TCP/IP component available under "Peripheral" on the toolbar? Which other components are not available?

If there is no TCP/IP component, then there was probably a problem during installation. I believe there are other posts (either in this forum or in the FAQs) that deal with component re-registration.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

Yes, there is a TCP/IP component available under "Peripheral". Everything in the toolbar is working. The only examples that I have found that isn't working are the ones I already pointed out. Tomorrow I will download them again and see what happens. I'll let you know.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

OK. I downloaded the examples for Flowcode V4 from >support>software downloads,patches and updates.(twice) I unzipped the files and then try to open the TCP components. I get the same error as before. SMTP and ping are the only two that work under TCP. When I add TCP to a project, it works fine. Only the examples don't work. Please help.

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

Please post the example that does not work to this forum and I will try that one.

felix341
Posts: 9
Joined: Fri Dec 18, 2009 1:26 am

Re: Component not registered

Post by felix341 »

Here are two of them. In case it matters, Flowcode V4.2.3.58

thanks again
Attachments
SEND_HTML_01.fcf
(15 KiB) Downloaded 260 times
RECV_HTML_01.fcf
(8 KiB) Downloaded 283 times

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

That's strange - these files are V2 files, which cannot be directly imported into V4. I have converted them and you should be able to load the versions that are attached.

There are also some other examples here:
http://www.matrixmultimedia.com/softwar ... amples.zip
Attachments
RECV_HTML_01a.fcf
(12 KiB) Downloaded 305 times
SEND_HTML_01a.fcf
(17.48 KiB) Downloaded 253 times

beambase
Posts: 94
Joined: Wed Jul 29, 2009 5:15 pm
Has thanked: 6 times
Been thanked: 8 times

Re: Component not registered

Post by beambase »

Hi,
I have tried the RECV_HTML_01a example on a 16F877A and that works well.
Since the 16F877A is a bit cramped for memory I converted the example to run on a 18F452 that is pin compatible.

To get the example to compile without errors I had to add

#define TMR0 TMR0L

in the defines section of custom code of the TCP_IP component.

Entering
#define TMR0 tmr0l
as suggested before for the 18F series did not work but resulted in errors.
However. It seams as it is not a workable solution. The code executes onces and then for some reason gets stuck if I try to send the repeat it. After powerdown and reset the code will execute once again and then get stuck. On a 16F877A it runs as it should. Any ideas why and is there a solution to use this example on the 18F series of Pics?

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

Sorry, but the code is designed to run on the 16F877a and we have not tested it on other devices. I can't think of why it will not work on this chip and I have no examples for an 18F series chip.

You could try addign the following 2 defines:

Code: Select all

#define TMR0 TMR0L
#define tmr0 tmr0l

User avatar
Dan81
Valued Contributor
Valued Contributor
Posts: 268
Joined: Sun Jan 15, 2006 4:07 pm
Location: Albi France
Been thanked: 60 times
Contact:

Re: Component not registered

Post by Dan81 »

hello

In the C code icon " C Code for random port "
If you replace "FCV_SRC_PORT = tmr0; " with " FCV_SRC_PORT = TMR0; "

The compilation is OK.

But I can't test it in hardware.

Daniel

beambase
Posts: 94
Joined: Wed Jul 29, 2009 5:15 pm
Has thanked: 6 times
Been thanked: 8 times

Re: Component not registered

Post by beambase »

Hi,
the problem is that the tmr0 function does not return a random number. It is the same number that is beeing returned as the SRC_PORT all the time. And that makes a second Tx on the same port impossible until the connection has timed out and closed.
Ant one that knows how to make tmr0 return random numbers on the 18F452?

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

In the header files for the compiler TMR0L is defined as the register location, and not the register itself:

Code: Select all

#define TMR0L                 0x00000FD6 
If you look further down the header file, you will see the actual register definition:

Code: Select all

volatile char tmr0l                  @TMR0L;
So you should be using "tmr0l" instead of "TMR0L".

User avatar
Steve
Matrix Staff
Posts: 3434
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Component not registered

Post by Steve »

But looking further into this, there is a problem with the C code for the component. That in fact uses "TMR0" to generate a "random" port number. This is wrong - it should use "tmr0" (and if this changes, the definition "#define tmr0l tmr0" will work as required).

(edit) You will need to add this definition to the component C file because adding it in the "supplementary code" window will put it in the wrong place.

We will fix this in the C code and issue an update soon. In the meantime, the edit can be made manually to the "PIC_TCP_IP.c" file int he "Components" directory of Flowcode (on lines 921 and 922).

Post Reply