t90add

Members
  • Content count

    35
  • Joined

  • Last visited

Everything posted by t90add

  1. t90add

    Screen

    Hello, I was wondering if anybody has a means of attaching a LCD screen onto the papilio where we could graph inputs from the adc? It was a pretty simple process to do on arduino. Thanks
  2. t90add

    Wifi

    Is there anyway to get the papilios online? I've got a WiFi module from Digilent http://digilentinc.com/Products/Detail.cfm?NavPath=2,892,1037&Prod=CHIPKIT-WIFI-SHIELD. What should I know/do to get this thing live? Thanks!
  3. t90add

    Retrocade Megawing ADC

    I recently purchased this bundle from gadget factory. http://store.gadgetfactory.net/retrocade-megawing-bundle/ I am new to FPGAs but I have coded with Arduinos before. I understand that FPGAs are alot more useful since then can do operations in parallel as opposed to sequences (arduinos; which is why i purchased it). How can I use the ADC of the megawing? Ideally I have two analog inputs, which sample at the same frequency (250hz). I would then like to output this on a graph (maybe serial port on the computer? or a TFT screen?) Can some one show me to the right direction? Thanks.
  4. t90add

    Porting Libraries

    Yeah that just out puts more errors. I'll keep googling around. Thanks tho!
  5. t90add

    Porting Libraries

    Hi, Does anybody have a method of porting libraries? Thanks
  6. t90add

    Porting Libraries

    okay, more errors In file included from wifi_example.ino:56:C:/Users/Qosmio/Documents/FPGA/zap-2.2.0-windows/papilio-zap-ide/libraries/WiFiShieldOrPmodWiFi_G/WiFiShieldOrPmodWiFi_G.h:70:21: warning: no newline at end of filewifi_example.ino: In function `void loop()':wifi_example.ino:264: warning: comparison between signed and unsigned integer expressionsIn file included from C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\DNETcK.cpp:39:C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\/./utility/DNETcKAPI.h:157:23: warning: no newline at end of fileC:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\DNETcK.cpp: In static member function `static bool DNETcK::begin(const IPv4&, const IPv4&)':C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\DNETcK.cpp:111: warning: aggregate has a partly bracketed initializerC:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\DNETcK.cpp: In static member function `static long unsigned int DNETcK::secondsSinceEpoch()':C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\DNETcK.cpp:316: warning: control reaches end of non-void functionIn file included from C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp:39:C:/Users/Qosmio/Documents/FPGA/zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/utility/DNETcKAPI.h:157:23: warning: no newline at end of fileC:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp: In member function `bool TcpClient::isConnected(long unsigned int, DNETcK::STATUS*)':C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp:340: error: `millis' undeclared (first use this function)C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp:340: error: (Each undeclared identifier is reported only once for each function it appears in.)C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp:292: warning: unused variable 'fConnected'C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp: In member function `size_t TcpClient::writeStream(const byte*, size_t, long unsigned int, DNETcK::STATUS*)':C:\Users\Qosmio\Documents\FPGA\zap-2.2.0-windows\papilio-zap-ide\libraries\DNETcK\TcpClient.cpp:729: error: `millis' undeclared (first use this function)
  7. t90add

    Porting Libraries

    Also here is the sketch: /************************************************************************//* *//* TCPEchoClient *//* *//* A chipKIT DNETcK TCP Client application to *//* demonstrate how to use the TcpClient Class. *//* This can be used in conjuction with TCPEchoServer */ /* *//************************************************************************//* Author: Keith Vogel *//* Copyright 2011, Digilent Inc. *//************************************************************************//* This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA*//************************************************************************//* *//* *//************************************************************************//* Revision History: *//* *//* 12/19/2011(KeithV): Created *//* 2/7/2012(KeithV): Updated for WiFi *//* 11/13/2012(KeithV): Modified to be generic for all HW libraries *//* *//************************************************************************///******************************************************************************************//******************************************************************************************//***************************** SET YOUR CONFIGURATION *************************************//******************************************************************************************//******************************************************************************************/************************************************************************//* *//* Include ONLY 1 hardware library that matches *//* the network hardware you are using *//* *//* Refer to the hardware library header file *//* for supported boards and hardware configurations *//* *//************************************************************************///#include <WiFiShieldOrPmodWiFi.h> // This is for the MRF24WBxx on a pmodWiFi or WiFiShield#include <WiFiShieldOrPmodWiFi_G.h> // This is for the MRF24WGxx on a pmodWiFi or WiFiShield/************************************************************************//* Required libraries, Do NOT comment out *//************************************************************************/#include <DNETcK.h>#include <DWIFIcK.h>/************************************************************************//* *//* SET THESE VALUES FOR YOUR NETWORK *//* *//************************************************************************/char * szIPServer = "192.168.1.180"; // server to connect tounsigned short portServer = DNETcK::iPersonalPorts44 + 300; // port 44300// Specify the SSIDconst char * szSsid = "chipKIT";// select 1 for the security you want, or none for no security#define USE_WPA2_PASSPHRASE//#define USE_WPA2_KEY//#define USE_WEP40//#define USE_WEP104//#define USE_WF_CONFIG_H// modify the security key to what you have.#if defined(USE_WPA2_PASSPHRASE) const char * szPassPhrase = "Digilent"; #define WiFiConnectMacro() DWIFIcK::connect(szSsid, szPassPhrase, &status)#elif defined(USE_WPA2_KEY) DWIFIcK::WPA2KEY key = { 0x27, 0x2C, 0x89, 0xCC, 0xE9, 0x56, 0x31, 0x1E, 0x3B, 0xAD, 0x79, 0xF7, 0x1D, 0xC4, 0xB9, 0x05, 0x7A, 0x34, 0x4C, 0x3E, 0xB5, 0xFA, 0x38, 0xC2, 0x0F, 0x0A, 0xB0, 0x90, 0xDC, 0x62, 0xAD, 0x58 }; #define WiFiConnectMacro() DWIFIcK::connect(szSsid, key, &status)#elif defined(USE_WEP40) const int iWEPKey = 0; DWIFIcK::WEP40KEY keySet = { 0xBE, 0xC9, 0x58, 0x06, 0x97, // Key 0 0x00, 0x00, 0x00, 0x00, 0x00, // Key 1 0x00, 0x00, 0x00, 0x00, 0x00, // Key 2 0x00, 0x00, 0x00, 0x00, 0x00 }; // Key 3 #define WiFiConnectMacro() DWIFIcK::connect(szSsid, keySet, iWEPKey, &status)#elif defined(USE_WEP104) const int iWEPKey = 0; DWIFIcK::WEP104KEY keySet = { 0x3E, 0xCD, 0x30, 0xB2, 0x55, 0x2D, 0x3C, 0x50, 0x52, 0x71, 0xE8, 0x83, 0x91, // Key 0 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Key 1 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, // Key 2 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; // Key 3 #define WiFiConnectMacro() DWIFIcK::connect(szSsid, keySet, iWEPKey, &status)#elif defined(USE_WF_CONFIG_H) #define WiFiConnectMacro() DWIFIcK::connect(0, &status)#else // no security - OPEN #define WiFiConnectMacro() DWIFIcK::connect(szSsid, &status)#endif //******************************************************************************************//******************************************************************************************//***************************** END OF CONFIGURATION ***************************************//******************************************************************************************//******************************************************************************************typedef enum{ NONE = 0, WRITE, READ, CLOSE, DONE,} STATE;STATE state = WRITE;unsigned tStart = 0;unsigned tWait = 5000;TcpClient tcpClient;byte rgbRead[1024];int cbRead = 0;// this is for Print.write to printbyte rgbWrite[] = {'*','W','r','o','t','e',' ','f','r','o','m',' ','p','r','i','n','t','.','w','r','i','t','e','*','\n'};int cbWrite = sizeof(rgbWrite);// this is for tcpClient.writeStream to printbyte rgbWriteStream[] = {'*','W','r','o','t','e',' ','f','r','o','m',' ','t','c','p','C','l','i','e','n','t','.','w','r','i','t','e','S','t','r','e','a','m','*','\n'};int cbWriteStream = sizeof(rgbWriteStream);/*** void setup() * * Parameters: * None * * Return Values: * None * * Description: * * Arduino setup function. * * Initialize the Serial Monitor, and initializes the * connection to the TCPEchoServer * Use DHCP to get the IP, mask, and gateway * by default we connect to port 44300 * * ------------------------------------------------------------ */void setup() { DNETcK::STATUS status; int conID = DWIFIcK::INVALID_CONNECTION_ID; Serial.begin(9600); Serial.println("WiFiTCPEchoClient 1.0"); Serial.println("Digilent, Copyright 2012"); Serial.println(""); if((conID = WiFiConnectMacro()) != DWIFIcK::INVALID_CONNECTION_ID) { Serial.print("Connection Created, ConID = "); Serial.println(conID, DEC); state = WRITE; } else { Serial.print("Unable to connection, status: "); Serial.println(status, DEC); state = CLOSE; } // use DHCP to get our IP and network addresses DNETcK::begin(); // make a connection to our echo server tcpClient.connect(szIPServer, portServer);}/*** void loop() * * Parameters: * None * * Return Values: * None * * Description: * * Arduino loop function. * * We are using the default timeout values for the DNETcK and TcpClient class * which usually is enough time for the Tcp functions to complete on their first call. * * This code will write some stings to the server and have the server echo it back * * ------------------------------------------------------------ */void loop() { int cbRead = 0; switch(state) { // write out the strings case WRITE: if(tcpClient.isConnected()) { Serial.println("Got Connection"); tcpClient.writeStream(rgbWriteStream, cbWriteStream); // write() should all fail to compile // while write is inherited from Print, we Hide this in the TcpClient class // as writeStream should be used; and we don't want confusing and competing calls // we just want to inherit the print() and println() methods from Print in TcpClient //tcpClient.write("Printed from tcpClient.write"); //tcpClient.write(rgbWrite, cbWrite); //tcpClient.write((uint8_t) 'b'); // check that print() and println() work tcpClient.print("*Printed from tcpClient.print*\n"); tcpClient.println("*Printed from tcpClient.println*"); // however, tcpClient "is-a" Print, so if I pass it as a Print // interally it should work as-a Print. printWrite(tcpClient); Serial.println("Bytes Read Back:"); state = READ; tStart = (unsigned) millis(); } break; // look for the echo back case READ: // see if we got anything to read if((cbRead = tcpClient.available()) > 0) { cbRead = cbRead < sizeof(rgbRead) ? cbRead : sizeof(rgbRead); cbRead = tcpClient.readStream(rgbRead, cbRead); for(int i=0; i < cbRead; i++) { Serial.print((byte) rgbRead[i]); } } // give us some time to get everything echo'ed back else if( (((unsigned) millis()) - tStart) > tWait ) { Serial.println(""); state = CLOSE; } break; // done, so close up the tcpClient case CLOSE: tcpClient.close(); Serial.println("Closing TcpClient, Done with sketch."); state = DONE; break; case DONE: default: break; } // keep the stack alive each pass through the loop() DNETcK::periodicTasks(); }/*** void printWrite(Print& print) * * Parameters: * print - This is a Print object to check to see if it works * * Return Values: * None * * Description: * * * If we pass a TcpClient into a fuction taking Print, all Print methods should * work as TcpClient "is-a" Print. * * ------------------------------------------------------------ */void printWrite(Print& print){ // check the print() and println() methods tcpClient.print("*Printed from print.print*\n"); tcpClient.println("*Printed from print.println*"); // While these are hidden from TcpClient // they should not be hidden from Print // these should all work. print.write((uint8_t) 'b'); print.write("\n*Wrote from print.write*\n"); print.write(rgbWrite, cbWrite);}
  8. t90add

    Porting Libraries

    Thanks! It seems like it solved those issues, however it produced these errors: In file included from wifi_example.ino:61:zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:303: error: `TcpClient::~TcpClient()' and `virtual TcpClient::~TcpClient()' cannot be overloadedwifi_example.ino: In function `void loop()':wifi_example.ino:264: warning: comparison between signed and unsigned integer expressionszap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h: In function `void __static_initialization_and_destruction_0(int, int)':zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:280: error: `virtual TcpClient::~TcpClient()' is privatewifi_example:145: error: within this context
  9. t90add

    Porting Libraries

    Sorry, do I just copy and paste it into DNETcK.h? I'm guessing its going to be copied over the problem areas and not the code
  10. t90add

    Porting Libraries

    Hi alvie, it actually worked? Anyways, Its from http://digilentinc.com/Agreement.cfm?DocID=DSD-0000318. I'm on error number 2 now.
  11. t90add

    Porting Libraries

    Okay thanks! I'll edit this list as I go along. Errors: error: integer constant is too large for 'long' type In function 'void setup()':In file included from wifi_example.ino:61:C:/Users/Qosmio/Documents/FPGA/zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:294: error: conflicting return type specified for `virtual void TcpClient::write(uint8_t)'zap-2.2.0-windows/papilio-zap-ide/hardware/zpuino/zpu/cores/zpuino/Print.h:48: error: overriding `virtual size_t Print::write(uint8_t)'zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:296: error: conflicting return type specified for `virtual void TcpClient::write(const uint8_t*, size_t)'zap-2.2.0-windows/papilio-zap-ide/hardware/zpuino/zpu/cores/zpuino/Print.h:53: error: overriding `virtual size_t Print::write(const uint8_t*, size_t)'zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:265: warning: `class TcpClient' has virtual functions but non-virtual destructorwifi_example.ino: In function `void loop()':wifi_example.ino:264: warning: comparison between signed and unsigned integer expressionsEdit: Solutions: Solution for error 1: add LL at the end of the constant. i.e. static const unsigned long msInfinite = 0xFFFFFFFFFFFFFFFFLL;Solution for error 2: change "void" to "size_t" i.e. size_t write(uint8_t bData);
  12. t90add

    Porting Libraries

    Thanks! I'll give you an update of what I find, otherwise I'll just have a setup where the papilio takes in data via adc, then tx data to another arduino that has the wifi shield ready to go.
  13. t90add

    Porting Libraries

    So I have this WiFi shield from Digilent http://digilentinc.com/Products/Detail.cfm?NavPath=2,892,1037&Prod=CHIPKIT-WIFI-SHIELD. To use it, I would need to use these header files: #include <WiFiShieldOrPmodWiFi_G.h>#include <DNETcK.h>#include <DWIFIcK.h>Using ZAP, I get the following errors: In file included from Mod_Analog_Wing_WiFi.ino:5:zap-2.2.0-windows/papilio-zap-ide/libraries/WiFiShieldOrPmodWiFi_G/WiFiShieldOrPmodWiFi_G.h:70:21: warning: no newline at end of fileIn file included from Mod_Analog_Wing_WiFi.ino:6:zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:181: error: integer constant is too large for "long" typezap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:294: error: conflicting return type specified for `virtual void TcpClient::write(uint8_t)'zap-2.2.0-windows/papilio-zap-ide/hardware/zpuino/zpu/cores/zpuino/Print.h:48: error: overriding `virtual size_t Print::write(uint8_t)'zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:296: error: conflicting return type specified for `virtual void TcpClient::write(const uint8_t*, size_t)'zap-2.2.0-windows/papilio-zap-ide/hardware/zpuino/zpu/cores/zpuino/Print.h:53: error: overriding `virtual size_t Print::write(const uint8_t*, size_t)'zap-2.2.0-windows/papilio-zap-ide/libraries/DNETcK/DNETcK.h:265: warning: `class TcpClient' has virtual functions but non-virtual destructor
  14. t90add

    Screen

    Nice! Well I got the code working! Turns out my big issue was having the screen connected to the board whilst the papilio was being updated with arduino code. So keep that in mind. Code is a little buggy (plotting too many pixels, about 70 readings are lost, but whatever lol). #include "SPIADC.h"#include "SPI.h"int CurVal; // Analog valueint i=1,j=2; // for indexing loopint y[200];HardwareSerial MySerial1(6); // within the paranthesis, place the wishbone for the UART (mine is 6).void setup() { // put your setup code here, to run once: //tx goes to pin 0 //rx goes to pin 1 MySerial1.begin(9600); // What I called the uart. Serial.begin(9600); analog.begin(CS(WCH4),WISHBONESLOT(5),ADCBITS(SPIADC_12BIT)); delay(5000); // Delay a bit for the screen to start running/*MySerial1.write(0xFF);MySerial1.write(0x68);MySerial1.write((byte)0x00);MySerial1.write((byte)0x03);*/ }void loop() { if (MySerial1.available()){// Inorder for the screen to recognize a command, it needs to be sent via MySerial1.write(SOME HEX NUMBER). Note the command sheet that accomponies the screen for commands ect.. MySerial1.write((byte)0x00); MySerial1.write(0x06); MySerial1.write(0x48); MySerial1.write(0x65); MySerial1.write(0x6C); MySerial1.write(0x6C); MySerial1.write(0x6F); MySerial1.write((byte)0x00); } delay(2000);// To Clear Screen MySerial1.write(0xFF); MySerial1.write(0xD7); // Uncomment this after sending any commands to the screen, so that you can see if it was accpeted by the screen (i.e. it should return '6' or '0x06')/*if (MySerial1.available() ){ Serial.println(MySerial1.read());} *//*// Putting it in portrait reverse (corresponds to 0x03, the last bit). MySerial1.write(0xFF);MySerial1.write(0x68);MySerial1.write((byte)0x00);MySerial1.write((byte)0x03);*//* Putting 1 char as in hex which is displayed as char on screen (NOT INT) Serial.println("Sending 2"); MySerial1.write(0xFF); MySerial1.write(0xFE); MySerial1.write((byte)0x00); MySerial1.write(0x39); */ //Putting string into screen (I think it says Hello)// Alternativly, you could send MySerial.print('Hello') <-- I think that works too. /* MySerial1.write((byte)0x00); MySerial1.write(0x06); MySerial1.write(0x48); MySerial1.write(0x65); MySerial1.write(0x6C); MySerial1.write(0x6C); MySerial1.write(0x6F); MySerial1.write((byte)0x00); */ // Drawing a Line. (x1,y1) to (x2,y2) then color. /* MySerial1.write(0xFF); MySerial1.write(0xD2); MySerial1.write((byte)0x00); MySerial1.write(0x0A); MySerial1.write((byte)0x00); MySerial1.write(0x0F); MySerial1.write((byte)0x00); MySerial1.write(0x28); MySerial1.write((byte)0x00); MySerial1.write(0x3C); MySerial1.write(0x04); MySerial1.write(0x10); */// The below loop is for aquiring data and building it as an array//for (i=0; i<100; i++){//Serial.println(analog.read(0));}// Serial.println(analog.read(0));//MySerial1.flush();// To draw a linefor (i=0;i<200;i++){ y[i]=analog.read(0)/50;delay(50);}i=0;j=1;while (j< 190) { // MySerial1.write(0xFF);// MySerial1.write(0xD2); //put pixel MySerial1.write(0xFF); MySerial1.write(0xCB); MySerial1.write((byte)0x00); MySerial1.write(i); MySerial1.write((byte)0x00); MySerial1.write(y[i]); // MySerial1.write((byte)0x00); // MySerial1.write(j); // MySerial1.write((byte)0x00); // MySerial1.write(y[j]); MySerial1.write(0x04); MySerial1.write(0x10);// Serial.println(y[i]);// Serial.println(y[j]);Serial.print("Y[i]=");Serial.print(y[i]);Serial.print(", Count i=");Serial.print(i);Serial.print(", Rx = ");Serial.println(MySerial1.read());/*Serial.println(" ");Serial.print("y=");Serial.print(y[i]);Serial.print(",i=");Serial.print(i);Serial.println("");Serial.print("y=");Serial.print(y[j]);Serial.print(",j=");Serial.print(j);Serial.println("-----");*///MySerial1.flush(); i=i+1; j=j+1; /* if (i >8){ MySerial1.write((byte)0x00); MySerial1.write(0x06); MySerial1.write(0x48); MySerial1.write(0x65); MySerial1.write(0x6C); MySerial1.write(0x6C); MySerial1.write(0x6F); MySerial1.write((byte)0x00); } */ } MySerial1.flush(); delay(200);}// delay(100);}
  15. t90add

    Screen

    Right, we can do both! So here is what I did, and what I have running via Uart. 1) Start the WINGAnalog xise file. 2) Delete one of the wishbones 3) Add the UART wishbone to the previously deleted site. Note the wishbone site number (mine is 6). 4) generate the bit file 5) load to SPI flash 6) Start zapuino with analogWING example. (We plan on taking a reading from the wing, then plotting it onto the display/screen). #include "SPIADC.h"#include "SPI.h"int CurVal; // Analog valueint i=0; // for indexing loopHardwareSerial MySerial1(6); // within the paranthesis, place the wishbone for the UART (mine is 6).void setup() { // put your setup code here, to run once: //tx goes to pin 0 //rx goes to pin 1 Serial.begin(9600); MySerial1.begin(9600); // What I called the uart. analog.begin(CS(WCH4),WISHBONESLOT(5),ADCBITS(SPIADC_12BIT)); delay(5000); // Delay a bit for the screen to start running}void loop() { // Inorder for the screen to recognize a command, it needs to be sent via MySerial1.write(SOME HEX NUMBER). Note the command sheet that accomponies the screen for commands ect.. // To Clear Screen /* Serial.println("Sending"); MySerial1.write(0xFF); MySerial1.write(0xD7); Serial.println("Sending back");*/ // Uncomment this after sending any commands to the screen, so that you can see if it was accpeted by the screen (i.e. it should return '6' or '0x06')/*if (MySerial1.available() ){ Serial.println(MySerial1.read());} *//*// Putting it in portrait reverse (corresponds to 0x03, the last bit). MySerial1.write(0xFF);MySerial1.write(0x68);MySerial1.write((byte)0x00);MySerial1.write((byte)0x03);*//* Putting 1 char as in hex which is displayed as char on screen (NOT INT) Serial.println("Sending 2"); MySerial1.write(0xFF); MySerial1.write(0xFE); MySerial1.write((byte)0x00); MySerial1.write(0x39); */ //Putting string into screen (I think it says Hello)// Alternativly, you could send MySerial.print('Hello') <-- I think that works too. /* MySerial1.write((byte)0x00); MySerial1.write(0x06); MySerial1.write(0x48); MySerial1.write(0x65); MySerial1.write(0x6C); MySerial1.write(0x6C); MySerial1.write(0x6F); MySerial1.write((byte)0x00); */ // Drawing a Line. (x1,y1) to (x2,y2) then color. /* Serial.println("Sending 2"); MySerial1.write(0xFF); MySerial1.write(0xD2); MySerial1.write((byte)0x00); MySerial1.write(0x0A); MySerial1.write((byte)0x00); MySerial1.write(0x0F); MySerial1.write((byte)0x00); MySerial1.write(0x28); MySerial1.write((byte)0x00); MySerial1.write(0x3C); MySerial1.write(0x04); MySerial1.write(0x10); */What to do next: 1) build loop to index and store values from the adc to an array. 2) index through the values and plot as (index, y1) to (index ++, y1). For some reason, it does not plot it correctly? Also it does it very slowly.
  16. t90add

    Screen

    Right, and I should send one of these commands to it. http://www.parallax.com/sites/default/files/downloads/28081-Goldelox-Spe-Command-set-v1.3.pdf If you take a look at page 32, there is a clear command. 0xFFD7 I suppose it would be something like mySerial.print(0xFFD7,HEX) Thanks
  17. t90add

    Screen

    That's fine. I'm trying to get used to the Schematic editor. Essentially I would need to incorporate one serial wishbone, then use it to tx data to the display's rx? Thanks
  18. t90add

    Screen

    Picked one up Edit: Would it be best to get that and the Breadboard? Edit2: Got both anyways
  19. t90add

    Screen

    Well I was thinking that I would just use the Retrocade Megawing's ADCs, where I would take two signals. I would store these 2 signals into one array (with some size C). I would then send this array after some clock period to the TX which would connect to the RX of the LCD Screen. Then on the LCD screen I would plot both signals concurrently. I think.
  20. t90add

    Screen

    Update: So I emailed support (of 4d systems), they said it is possible. Essentially: 1) I will need to stream out a register data 2) The screen will need to buffer the register data being streamed from the FPGA, and use the Spectrum widget (or Scope widget) to simulate the graph using ViSi Environment of workshop (since I want to plot the values from the ADC of the papilio) 3) On the FPGA, I will need to model a circuit for the ADC register and UART (making sure that the baud rates of papilio and the screen are equal). Edit: I'm not completely sure on how to do any of this
  21. t90add

    Screen

    Yup, the Goldelox processor is pretty powerful. Have you purchased a "4D systems programmer"? It allows you to make the embedded processor(i.e. Goldelox) either a master or slave(i.e. a screen that takes the .gfx commands from another microprocessor like an arduino for example or Papilio presumably). Actually now that I think about it, I think you need the programmer to program the tft screen with "Workshop"...? Edit: Links Programmer: http://www.4dsystems.com.au/product/17/114/Accessories/4D_Programming_Cable/ Workshop IDE: http://www.4dsystems.com.au/product/10/120/Development/4D_Workshop_4_IDE/ Demos: https://mbed.org/users/4180_1/notebook/ulcd-144-g2-128-by-128-color-lcd/
  22. t90add

    Screen

    Nice!
  23. t90add

    Screen

    I purchased mine from: https://www.sparkfun.com/products/11377, unfortunately they are out of stock at the moment (supposedly until Feb-19). These guys have some in stock http://www.robotshop.com/en/4d-systems-serial-lcd-tft-display-module.html?utm_source=google&utm_medium=base&utm_campaign=GoogleUSA Edit: Here is a cheaper alternative http://microcontrollershop.com/product_info.php?products_id=4058&gclid=CMGvub6us7wCFZDm7AodxnUAqA.
  24. t90add

    Screen

    Yup! Do you mind showing me how? Many thanks!
  25. t90add

    Screen

    Is there anyway to use this lcd display? http://www.soselectronic.hu/a_info/resource/c/4Dsystem/uLCD-144-G2GFX-DS-rev1.pdf I've used it with arduino/chipkits before.