The HMC5883L.h include file is the driver for your device. HMC5883L.h is depenent on I2C.H. I2C.H is automatically loaded as you compile your source code. There a host of other files that are loaded during compilation to provide the rich set of commands within Great Cow Basic.
The rational to ask you to upgrade is. I2C.H does not work correctly in releases prior 2014 and we have fixed many, too many to list, 16F Microchip memory management issues.
I am about to release another release. In a day or two. And, once this is released I would recommend that everyone upgrades to the latest version to add a host of functionality we have added since March 2015 and to further improved Great Cow Basic's stability.
Please upgrade and then we have you on a stable version. See the front page of this website for the Download button. https://sourceforge.net/projects/gcbasic/ Please select' Hot Release of Great Cow Basic version 0.94 March 2015' when the next release comes out I would upgrade asap as more 16F memory issues are resolved.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK I am downloading hot release will try again next week. I think it is improtant to get this driver to working as it will open up more Pallax sensors like GPS , gryos and accelerometers.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi, I installed hot realse. It made crimson editor quit working! I do not see the connection. Even won't work if I restorw the orignal set up. Do I cannot compile and down load the way I used to. Any ideas on this?
GCBIDE works OK with new release, but it compiles to the location folder with the file name. Is there any way to set up GCBIDE to put "compiled.asm and .hex" in the GCB root folder, that will make it easier to use. GCBIDE has lousy graphics on my computer. When I get this fixed I can start testing again. Thanks, Ed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ed - sorry. Did you backup up your old installation folder? I will revised the download page to make this more clear.
I am not sure why Crimson does not work but if you over wrote your install then this was probably the cause.
GCBIDE? I am puzzled. In the Hot Releases since 2013 we have included GCB@Syn. GCB@Syn is an IDE for Great Cow Basic. You start this via IDE.EXE
When you say GCBIDE has poor graphics. I think you are referring to Great Cow Graphical Basic. As you used Crimson before I would reccomend using GCB@Syn (IDE.EXE).
GCB@Syn is now maintained with IDE Helpers and inline Help. We are maintaining GCB@Syn going forward.
Hope this helps.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi started out new with sample code, modified it to work with my serial LCD. Compiles by drag and drop to GCB..exe. Get thsi error "HMC5883L.h <102> syntex error. Reloaded Crimson Editor no change. IDE to confuing for now will take a learning curve.
Is there any way to set up GCBIDE to put "compiled.asm and .hex" in the GCB root folder, that will make it easier to use. GCBIDE has lousy graphics on my computer. When I get this fixed I can start testing again. Thanks, Ed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Here goes. If your GCBIDE is this one. See http://gcbasic.sourceforge.net/temp/InstallGCBIDE20.exe I just installed. I changed the setup in the 'Environment Setup' to point to GCBASIC.EXE and my programmer. And, compiles, creates ASM and HEX ok.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
@Ed. You are totallly correct - there was an error at line 102. I recompile the test code and got the same error here just now.
Please download from here a new driver that should compile. Please install this new driver in your include folder.
Really sorry, I added an initialisation of the Hardware I2C at line 102 and I introduced an error. This happens when I do not have the hardware to test. :-) Sorry Ed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi downloaded new driver same error :HMC5883L.h (102): Error: Syntax Error on my modified progam.
I downloaded your sample program with no changes get the same error: HMC5883L.h (102): Error: Syntax Error. Now what? Ed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
OK I was too blurry eyed last night to realise I was modifing the .h file in the wrong folder. commenting it out allows it to comile properly. I will have to test it to see if it works later.
Question was is the purpose of the HIC2Init command? will it work with out it? Thanks, Ed.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I thought is was a file/folder isssue. Phew. I was starting to scratch my head.
HIC2INIT is a supporting function when you are using harware IC2. We develop drivers that support both software and hardware I2C. HIC2INIT is the explicit method use to setup the hardware I2C module.
Good luck testing later.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Ok here the way it stands now. Using HI2C commands does not work! Not data or clock signals. Changing it to I2C makes it work, data and clock signals Reads all 3 channels as FF. Now were do we go. Note: the HIC2init was commented out maybe that is why HW does not work
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
There is something odd going on. Can you do a new install? Download the Hot Release, then install the revised .H (download from SourceForge again) and please try to complile the Hot Release IDE, simple press <f6>. If it does not compile then I will ask you to edit the compile batch file to show all the errors.</f6>
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
My code does not produce any errors. I modified the .h file. called it SHMC5883L.h to change all HI2C commands to I2C. It compiles without error. Will test it tomorrow. Attached below
Could not wait tested it just now. Compiles with no errors. Same result All FF. Your harware I2C does not work. There are no clock and data signals. Hardware I2c Produces no LCD diaplay. With I2C works OK with data and colck siganls and it displays FF.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hardware does not work on the 16f88 as the 16f88 does not have the requuired module. You have to use Software I2C.
Do you have any tools to see the clock /data signals? I know the SW I2C typically works as I have an extensive test rig for testing prior releasing code - but, I, as you know, do have the same hardware as you. :-(
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Why is HIC2 code being referenced when this code should not have compiled? The only way the HIC2 code should be compiled is when you have HIC2_DATA defined - which you do not. This is puzzling me.
I know the I2C code works. But, when the I have the issue of HIC2 code being compiled when it should not be... really worries me.
Let me look at the ASM.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The HMC5883L.h include file is the driver for your device. HMC5883L.h is depenent on I2C.H. I2C.H is automatically loaded as you compile your source code. There a host of other files that are loaded during compilation to provide the rich set of commands within Great Cow Basic.
The rational to ask you to upgrade is. I2C.H does not work correctly in releases prior 2014 and we have fixed many, too many to list, 16F Microchip memory management issues.
I am about to release another release. In a day or two. And, once this is released I would recommend that everyone upgrades to the latest version to add a host of functionality we have added since March 2015 and to further improved Great Cow Basic's stability.
Please upgrade and then we have you on a stable version. See the front page of this website for the Download button. https://sourceforge.net/projects/gcbasic/ Please select' Hot Release of Great Cow Basic version 0.94 March 2015' when the next release comes out I would upgrade asap as more 16F memory issues are resolved.
OK I am downloading hot release will try again next week. I think it is improtant to get this driver to working as it will open up more Pallax sensors like GPS , gryos and accelerometers.
Hi, I installed hot realse. It made crimson editor quit working! I do not see the connection. Even won't work if I restorw the orignal set up. Do I cannot compile and down load the way I used to. Any ideas on this?
GCBIDE works OK with new release, but it compiles to the location folder with the file name. Is there any way to set up GCBIDE to put "compiled.asm and .hex" in the GCB root folder, that will make it easier to use. GCBIDE has lousy graphics on my computer. When I get this fixed I can start testing again. Thanks, Ed.
Ed - sorry. Did you backup up your old installation folder? I will revised the download page to make this more clear.
I am not sure why Crimson does not work but if you over wrote your install then this was probably the cause.
GCBIDE? I am puzzled. In the Hot Releases since 2013 we have included GCB@Syn. GCB@Syn is an IDE for Great Cow Basic. You start this via IDE.EXE
When you say GCBIDE has poor graphics. I think you are referring to Great Cow Graphical Basic. As you used Crimson before I would reccomend using GCB@Syn (IDE.EXE).
GCB@Syn is now maintained with IDE Helpers and inline Help. We are maintaining GCB@Syn going forward.
Hope this helps.
Hi started out new with sample code, modified it to work with my serial LCD. Compiles by drag and drop to GCB..exe. Get thsi error "HMC5883L.h <102> syntex error. Reloaded Crimson Editor no change. IDE to confuing for now will take a learning curve.
Is there any way to set up GCBIDE to put "compiled.asm and .hex" in the GCB root folder, that will make it easier to use. GCBIDE has lousy graphics on my computer. When I get this fixed I can start testing again. Thanks, Ed.
I think so, is this the GCBIDE http://www.freewarefiles.com/GCBIDE_program_38410.html you are using? If can quickly upload (as an attachment) GCBIDE I should be able to get the setup working.
Meanwhile, in the new GCB@SYN load your source file and press F6 - this should compile your file. Remember to copy HMC5883L.h to the include folder.
Here goes. If your GCBIDE is this one. See http://gcbasic.sourceforge.net/temp/InstallGCBIDE20.exe I just installed. I changed the setup in the 'Environment Setup' to point to GCBASIC.EXE and my programmer. And, compiles, creates ASM and HEX ok.
@Ed. You are totallly correct - there was an error at line 102. I recompile the test code and got the same error here just now.
Please download from here a new driver that should compile. Please install this new driver in your include folder.
Really sorry, I added an initialisation of the Hardware I2C at line 102 and I introduced an error. This happens when I do not have the hardware to test. :-) Sorry Ed.
Hi downloaded new driver same error :HMC5883L.h (102): Error: Syntax Error on my modified progam.
I downloaded your sample program with no changes get the same error: HMC5883L.h (102): Error: Syntax Error. Now what? Ed.
Odd. Are you sure you have the .h file in the correct folder? Should be in the include folder.
As you are testing. Comment out line 102. Does this remove the error?
amazingly no Have no idea why that is why don't you try it out to see what you get. it did before this time. Ed.
OK I was too blurry eyed last night to realise I was modifing the .h file in the wrong folder. commenting it out allows it to comile properly. I will have to test it to see if it works later.
Question was is the purpose of the HIC2Init command? will it work with out it? Thanks, Ed.
I thought is was a file/folder isssue. Phew. I was starting to scratch my head.
HIC2INIT is a supporting function when you are using harware IC2. We develop drivers that support both software and hardware I2C. HIC2INIT is the explicit method use to setup the hardware I2C module.
Good luck testing later.
I think that HIC2Init may be should be HI2CInit. I tryed that and it did not work either.
I just tested the code again on a test rig - all works ok. I used this file https://sourceforge.net/p/gcbasic/code/HEAD/tree/GCBASIC/trunk/include/HMC5883L.h
I used the Compass demo as my source code.
Can you attached you latest source code? This will help me.
Ok here the way it stands now. Using HI2C commands does not work! Not data or clock signals. Changing it to I2C makes it work, data and clock signals Reads all 3 channels as FF. Now were do we go. Note: the HIC2init was commented out maybe that is why HW does not work
Forgot this
I am not getting errors here compiling your code.
There is something odd going on. Can you do a new install? Download the Hot Release, then install the revised .H (download from SourceForge again) and please try to complile the Hot Release IDE, simple press <f6>. If it does not compile then I will ask you to edit the compile batch file to show all the errors.</f6>
I meant - do this in a new installation folder.
My code does not produce any errors. I modified the .h file. called it SHMC5883L.h to change all HI2C commands to I2C. It compiles without error. Will test it tomorrow. Attached below
Could not wait tested it just now. Compiles with no errors. Same result All FF. Your harware I2C does not work. There are no clock and data signals. Hardware I2c Produces no LCD diaplay. With I2C works OK with data and colck siganls and it displays FF.
Please attach your ASM file, please.
Hardware does not work on the 16f88 as the 16f88 does not have the requuired module. You have to use Software I2C.
Do you have any tools to see the clock /data signals? I know the SW I2C typically works as I have an extensive test rig for testing prior releasing code - but, I, as you know, do have the same hardware as you. :-(
A few things that have my wondering.
Why is HIC2 code being referenced when this code should not have compiled? The only way the HIC2 code should be compiled is when you have HIC2_DATA defined - which you do not. This is puzzling me.
I know the I2C code works. But, when the I have the issue of HIC2 code being compiled when it should not be... really worries me.
Let me look at the ASM.
What module do you need? I have these chips:PIC18F2525/2620/4525/4620 will they work?
Let me know how to proceed.
Forgot I have a scope to look at signals