I asked about the value of the resistors just to make sure that you are aware and its obvious that you know what you are doing - it is a good question to solicit that information. At some point you need to set the BV4618 to have 4 lines by 20 charters as the default is 16x20, this will affect cursor movements outside that range. It works by using the values stored in EEPROM set by the 0x32 comby jimeer - Serial & I2C Devices
Some questions: 1) What value of pull up resistors are you using? 2) What is the host?, the master device 3) What size is the displayby jimeer - Serial & I2C Devices
The fact that 1b 50 works and 1b 1 1 doesn’t points to something amiss with what is being sent, this would also account for the problems with moving the cursor. It looks as though the master I2C is capable of sending 2 bytes (1b 50) but not 3 or more.by jimeer - Serial & I2C Devices
hello, the reason a string is used in fwrite is because it is used in fread. A string contains its size and so when reading the buffer can't be exceeded by accident. So fwrite is just the opposite of fread. There may be some improvements needed around file access, open to suggestions for the next update. Jimby jimeer - ByPic
The bug here is that the string looses its size in the first 4 bytes when saved to flash. To be fixed in the next release. A workround is to put the size back on reset thus: poke(buff$,1024) There is still a problem with the sizing of strings on version 69 so the global save needs looking at.by jimeer - ByPic
It was 255 because the buffer size was stored in 8 bits but it now should be any size, limited by the available space. It is alloceated at run time and also when using the comopen command from the spare heap, when you do 'sys' it gives the space available, the current release is by defult 920 bytes. You have to specify a buffer size anyway when using the comopen command, the default 84 bytes isby jimeer - ByPic
Hello, There is a bug which is activated by the space after crc: function ComputeCrc16(buffer,ln,crc ) <<< remove space between crc and ) crctemp1 = 0 //l crctemp2 = 0 //h .............. For now this will fix it until the next release.by jimeer - ByPic
Only change the size of variable storage as a last resort. These are balanced, increasing one robs the program space. Local memory is created and destroyed as the function is entered and exited so look at the code and see how a local can take up so much space - look for an alternative. There is a FAQ with regard to strings being chopped off, this happens because the default string space is onlby jimeer - ByPic
Check the "Erase all flash" box on the, application bootloader before uploading the new version.by jimeer - ByPic
The heap is where the program and variables are stored, check by using "sys". If you have run out of ram program space then save some functions to flash using "flsave"by jimeer - ByPic
There is no risk, the reason that 115200 is default is that not all USB - serial devices or Linux for that matter can handle it but 2000000 Baud works very well in Windows.by jimeer - ByPic
This timeout is caused by a syntax error in your code: while(state=4) should be: while state = 4 There is no parenthesis for decision statements. It should report a syntax error but doesn’t. PS the dim problem has been fixed and will be due out in the next few hours.by jimeer - ByPic
The workrounds are in your code above.by jimeer - ByPic
yes, its a bug due to be fixed for next release.by jimeer - ByPic
Peekc is the best way to do it, e.g. value = peekc(?lut$+4+offset) or if you prefer data = ?lut$+4 value = peekc(data+offset) When the constant is defined as a string, the first 4 bytes are the storage size so the actual data starts at byte 4 (5th one along from 0). peek(?lut$) will give you the size of the byte array. dump(?lut$,32) can also be quite useful for verification Some poiby jimeer - BV523
You can't dynamically write to flash but you can store tables to flash in the latest version 2.06-67 in a similar way that you can in C using the constant keyword. So a lookup table of bytes would be: constant lut$ {1,2,3,0x55,77} You can only have a line length of 80 characters and so a continue ‘\’ symbol can be used for larger tables thus: constant lut$ {1,2,3,4,5,6,1,2,3,4,5,6,55,0xfby jimeer - BV523
You can't add a filled array to flash as it is stored in RAM and on reset the RAM could contain anything, an array is read/write. The array would still exist but it would need filling at runtime on start up. What you may be looking for is a constant. An array, byte constant is a sting, escape "\nn" can be used for non-printable characters. There is a limit of 80 characters per line whenby jimeer - BV500
try flsave("") *** this is open bracket double quote double quote close bracket - not winky smiley - must find out how to switch them off. see Keywords - flsaveby jimeer - BV500
Thanks for the update, I have fixed the link above. The product documentation is www.doc.byvac.com so it will take you back to that page. For mBasic documentation click on the "Documentation" menu.by jimeer - BV500
hello, try phisically swapping the tx and rx round so pin 0 goes to tx on the BV4108 and pin 1 goes to rx on the BV4108by jimeer - Serial & I2C Devices
Sorry, its me looking in the wrong place. To post code there is a code icon on the toolbar above next to the quotes icon.by jimeer - Serial & I2C Devices
I think you must be looking in the wrong place, the turotial is here: MX1 Tutorial Click on the Introduction at the right hand side and build the circuit on the breadboard (as it says).by jimeer - Serial & I2C Devices
machineBASIC may get a new name to reflect that it is not really BASIC and in no way represents the ZX Spectrums of the past which is the nostalgic road that most people go down when seeing the word BASIC. Regardless of what is beyond that word, as soon as it is seen massive assumptions are made and very few people investigate what the language is about. The language feature is that it allowsby jimeer - Announcements
All of the information is here: There is a zip file with a user guide and smaple VB code.by jimeer - Serial & I2C Devices
You need a com port to connect to the USB to serial device. See: here to understand why and also more information on loading.by jimeer - ByPic
To use the code that is on the internet, instead of selecting the URL, select the body of the code, i.e. everything that is on the blue page. Then open notepad (or PSPAD as I see you are using that) and paste into that so you have a copy of the code in notepad. Now save the notepad file to a local directory, it doesnt matter what it is called but by convention normally has .bas on the endby jimeer - BV500
The firmware on theBV500 is protected and there is also a get out procedure for creating a continuous loop so it is very difficult to stop it working alltogether. To program you don't need a programmer or MPLAB, just send a text file and the BV500 will do the compiling. If you want to use C, MPLAB and all of those tools then you just need to buy a PIC32MX150B without the firmware and program itby jimeer - BV500
Yes, you can add an external crystal and set the OSCCON register to use that instead of the internal one - see section 8 of the data sheet. The current configuration is as follows #if defined ( USE_EXT_XTAL ) # pragma config FNOSC = PRIPLL // Oscillator Selection: Primary oscillator (XT, HS, EC) w/ PL # pragma config POSCMOD = HS // Primary Oscillator: HS oscillator #else #by jimeer - BV500
It is mentioned at the beginning on page 8 under the heading Functions, but to make it clear you need to do two things for a stand alone system: 1) Simply create a function called 'main' and save that to flash. This function will be run at start up. 2) The the MCLR pin needs to be tied to 3.3V with a 10k resistor. Main() is going to be a continuous loop and if you have not built in any get oby jimeer - BV500