Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Reputation Activity

  1. Like
    PTB got a reaction from bluehash in Mailbag   
    This week I received my post of the month prize from Fred.
    He cut some panel sets for my project which look very nice. The photo doesn't do it justice.

    @@Fred Thanks again man. For the great job and putting up the prize on 43oh. Superchamp!
  2. Like
    PTB got a reaction from Fred in Mailbag   
    This week I received my post of the month prize from Fred.
    He cut some panel sets for my project which look very nice. The photo doesn't do it justice.

    @@Fred Thanks again man. For the great job and putting up the prize on 43oh. Superchamp!
  3. Like
    PTB reacted to maelli01 in 3phase variable speed motor drive   
    Hi there
    Here is my 3phase variable speed motor drive booster pack

    This has been in my mind for some years, but I always thought that a 3phase variable speed inverter drive is
    beyond my humble hobbyist scope. Too complicated for my old 8-bit mind ;-)

    Such a inverter contains:
    6 high voltage FETs or IGBTs, 6 gatedrives, at least one DSP, a protection concept,
    all the software to create the 3-phase PWM, dead time control.....

    Still that was for quite some time on my long-term "to do" list, with no chance to actually materialize it,
    not enough time, too many other things to do.

    When playing around with the PWM module of the TM4C123 I found out that creating a 3phase PWM
    signal with this module is actually pretty easy.
    Combined that with an integrated Power Module such as the FSB50550 (Fairchild).

    So here it is: a booster pack for the Tiva Launchpad which drives big-ass 3phase motors.

    The booster pack contains the following:
    - the FSB50550 power module (6 FETs 500V 1.4Ohm, Gatedrivers, Bootstrap diodes, Temp sensor)
    - snubber capacitor
    Power supply: everything is powered from one DC source, 20V or (much) more.
    - 15V switchmode power supply from the high voltage side, built around a LNK304, for the FSB50550
    - 3.3V switchmode power supply from the 15V to power the Launchpad, built around a LT1376
    - Passive voltage dividier to measure the input voltage
    - Sense resistor and LM339 comparator for overcurrent detection
    - Nokia 5110 display
    Potentiometer for motor speed and direction

    The software is based on Energia using Tiva Ware function calls for all the PWM stuff.
    It is still work in progress, very basic and at the moment consists of:

    - calculate the sinwave lookup table at startup
    - PWM initialisation (PWM set to 15625 Hz, deadtime 1us, sync on)
    - a timer interrupt run every 10uSecs, do update the 3 PWD duty cycles
    - ADC measurement of temperature, voltage, current (moving average)
    - fault interrupt

    The main program is very short, the display is updated twice a second and the modulation factor is calculated
    out of the potentiometer speed setting and the applied DC voltage.
    Sudden changes in motor frequency are limited in the software, to prevent the motor to feed back energy and cause

    The motor on the picture is a 1/2hp, 900rpm, 6-pole motor, 12 kg of Italian steel and copper, probably 50 years old.
    For playing around, I apply about 50% of rated volt/hz, so current and maximum torque is reduced.
    Currently I use my dual 35V 4A lab supply, series connected, as a power source.
    here is the code:
    //simple 3phase frequency converter //27.9.2014 by maelli #define dots 192 //dots per halfhave, must be divisible with 3 #define period 5120 //80Mhz/5120 = 15625 switching frequency #define dt 80 //deadtime 80Mhz / 80 = 1uS #define PART_TM4C123GH6PM #include <stdint.h> #include <stdbool.h> #include "inc/hw_ints.h" #include "inc/hw_sysctl.h" #include "inc/hw_types.h" #include "driverlib/interrupt.h" #include "driverlib/sysctl.h" #include "driverlib/timer.h" #include "driverlib/pwm.h" #include "LCD_5110.h" #include "inc/tm4c123gh6pm.h" LCD_5110 myScreen (33,37,36,35,34,38,17); char celsius[3]={0x7f,'C',0x00}; uint16_t a,dire=0,modu,tensec; uint32_t timecount,sintable[dots]; volatile int32_t irqcount,timeset; volatile uint32_t temperature, voltage, current, poti; void setup(){ myScreen.begin(); myScreen.setBacklight(0); myScreen.text(0, 0, "3ph Converter"); for(int i=0;i<dots;i++) sintable[i]=sinf((i*3.14159)/dots)*(period/2-dt); unsigned long ulPeriod; unsigned int Hz = 10000; // interupt frequency in Hz ulPeriod = (SysCtlClockGet() / Hz); initTimer(); charge_gdu(); ROM_TimerLoadSet(TIMER0_BASE, TIMER_A,ulPeriod -1); initPWM(); } void loop(){ if (irqcount>499) { //20x per sec irqcount-=500; int32_t fsoll=732*(poti-16384); int32_t diff=fsoll-timeset; if (diff>0){ if (diff>150000) timeset+=150000; else timeset=fsoll; } else { if (diff<-150000) timeset-=150000; else timeset=fsoll; } modu=abs(timeset)/voltage/16; if (modu<(32000/voltage)) modu=32000/voltage; if (modu>256) modu=256; tensec++; if (tensec==10) { //2x per sec we display something tensec=0; myScreen.text(0, 1, mkstrg((temperature-325)/24,2)); myScreen.text(2, 1, celsius); myScreen.text(5, 1, mkstrg((voltage)/23,3)); myScreen.text(8, 1, "Volt"); myScreen.text(0, 2, mkstrg(abs(timeset)/322122,2)); myScreen.text(2, 2, "."); myScreen.text(3, 2, mkstrg(abs((timeset/32212)%10),1)); myScreen.text(4, 2, "Hz"); myScreen.text(7, 2, mkstrg(current,4)); myScreen.text(11, 2, "mA"); if (timeset<0) myScreen.text(0, 3, "links "); else myScreen.text(0, 3, "rechts"); } } } String mkstrg(int d,uint8_t l){ char display[l+1]; int q=1; display[l]=0; for (uint8_t a=l;a;a--){ display[a-1]=0x30+(d%(q*10))/q; q*=10; } return display; } void initTimer(){ ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_TIMER0); ROM_TimerConfigure(TIMER0_BASE, TIMER_CFG_PERIODIC); // 32 bits Timer TimerIntRegister(TIMER0_BASE, TIMER_A, Timer0Isr); // Registering isr ROM_TimerEnable(TIMER0_BASE, TIMER_A); ROM_IntEnable(INT_TIMER0A); ROM_TimerIntEnable(TIMER0_BASE, TIMER_TIMA_TIMEOUT); } void charge_gdu(){ ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOA); ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOD); ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_GPIOF); ROM_GPIOPinTypeGPIOOutput(GPIO_PORTF_BASE, GPIO_PIN_0 ); ROM_GPIOPadConfigSet(GPIO_PORTF_BASE,GPIO_PIN_0,GPIO_STRENGTH_4MA,GPIO_PIN_TYPE_STD); GPIOPinTypeGPIOOutput(GPIO_PORTA_BASE, GPIO_PIN_7); //alle 3 oberen ausschalten HWREG(GPIO_PORTA_BASE + (GPIO_PIN_7 << 2)) = 0; GPIOPinTypeGPIOOutput(GPIO_PORTD_BASE, GPIO_PIN_1); HWREG(GPIO_PORTD_BASE + (GPIO_PIN_1 << 2)) = 0; GPIOPinTypeGPIOOutput(GPIO_PORTF_BASE, GPIO_PIN_3); HWREG(GPIO_PORTF_BASE + (GPIO_PIN_3 << 2)) = 0; GPIOPinTypeGPIOOutput(GPIO_PORTD_BASE, GPIO_PIN_0); //auch die 2 letzten aus HWREG(GPIO_PORTD_BASE + (GPIO_PIN_0 << 2)) = 0; GPIOPinTypeGPIOOutput(GPIO_PORTF_BASE, GPIO_PIN_2); HWREG(GPIO_PORTF_BASE + (GPIO_PIN_2 << 2)) = 0; GPIOPinTypeGPIOOutput(GPIO_PORTA_BASE, GPIO_PIN_6); //den ersten unteren ein HWREG(GPIO_PORTA_BASE + (GPIO_PIN_6 << 2)) = GPIO_PIN_6; delay(1); HWREG(GPIO_PORTD_BASE + (GPIO_PIN_0 << 2)) = GPIO_PIN_0; delay(1); HWREG(GPIO_PORTF_BASE + (GPIO_PIN_2 << 2)) = GPIO_PIN_2; delay(1); } void initPWM(){ ROM_SysCtlPeripheralEnable(SYSCTL_PERIPH_PWM1); //The Tiva Launchpad has two PWM modules (0 and 1). We are using 1 ROM_GPIOPinConfigure(GPIO_PD0_M1PWM0); ROM_GPIOPinConfigure(GPIO_PD1_M1PWM1); ROM_GPIOPinConfigure(GPIO_PA6_M1PWM2); ROM_GPIOPinConfigure(GPIO_PA7_M1PWM3); ROM_GPIOPinConfigure(GPIO_PF2_M1PWM6); ROM_GPIOPinConfigure(GPIO_PF3_M1PWM7); ROM_GPIOPinConfigure(GPIO_PF4_M1FAULT0); ROM_GPIOPinTypePWM(GPIO_PORTD_BASE, GPIO_PIN_0 | GPIO_PIN_1 ); ROM_GPIOPinTypePWM(GPIO_PORTA_BASE, GPIO_PIN_6 | GPIO_PIN_7 ); ROM_GPIOPinTypePWM(GPIO_PORTF_BASE, GPIO_PIN_2 | GPIO_PIN_3 | GPIO_PIN_4); PWM1_0_FLTSEN_R =3; //PWM fault inverted see page 1169 GPIO_PORTF_PUR_R=0x10; //weak pullup for Pin 4 ROM_PWMGenConfigure(PWM1_BASE, PWM_GEN_0, PWM_GEN_MODE_UP_DOWN | PWM_GEN_MODE_SYNC | PWM_GEN_MODE_FAULT_LEGACY); ROM_PWMGenConfigure(PWM1_BASE, PWM_GEN_1, PWM_GEN_MODE_UP_DOWN | PWM_GEN_MODE_SYNC | PWM_GEN_MODE_FAULT_LEGACY); ROM_PWMGenConfigure(PWM1_BASE, PWM_GEN_3, PWM_GEN_MODE_UP_DOWN | PWM_GEN_MODE_SYNC | PWM_GEN_MODE_FAULT_LEGACY); ROM_PWMGenPeriodSet(PWM1_BASE, PWM_GEN_0, period); ROM_PWMGenPeriodSet(PWM1_BASE, PWM_GEN_1, period); ROM_PWMGenPeriodSet(PWM1_BASE, PWM_GEN_3, period); ROM_PWMDeadBandEnable(PWM1_BASE, PWM_GEN_0, dt,dt); ROM_PWMDeadBandEnable(PWM1_BASE, PWM_GEN_1, dt,dt); ROM_PWMDeadBandEnable(PWM1_BASE, PWM_GEN_3, dt,dt); ROM_PWMSyncTimeBase(PWM1_BASE,PWM_GEN_0_BIT |PWM_GEN_1_BIT|PWM_GEN_3_BIT); ROM_PWMGenEnable(PWM1_BASE, PWM_GEN_0); ROM_PWMGenEnable(PWM1_BASE, PWM_GEN_1); ROM_PWMGenEnable(PWM1_BASE, PWM_GEN_3); delay(1); PWMFaultIntRegister(PWM1_BASE, oh_shit); ROM_PWMIntEnable(PWM1_BASE,PWM_INT_FAULT0); ROM_PWMOutputState(PWM1_BASE, PWM_OUT_0_BIT | PWM_OUT_1_BIT | PWM1_BASE | PWM_OUT_2_BIT | PWM_OUT_3_BIT |PWM_OUT_6_BIT | PWM_OUT_7_BIT, true); } void Timer0Isr(void) { //10000x per second ROM_TimerIntClear(TIMER0_BASE, TIMER_TIMA_TIMEOUT); // Clear the timer interrupt irqcount++; timecount+=timeset; // 1 Hz is 192x256*256*256/10000=322122.5 if (timecount> 0xEFFFFFFF) timecount+=0xC0000000; if (timecount> 0xBFFFFFFF) timecount-=0xC0000000;; a=timecount>>16; a=a/(16384/(dots/3*2)); //a immer kleiner 2*dots: C000 *dots/3*2/ 4000= 12 *dots/3*2/4= 2*dots if (a<dots)ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_0,period/2+sintable[a]*modu/256); else ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_0,period/2-sintable[a-dots]*modu/256); a=a+dots*2/3; if (a>=2*dots) a-=2*dots; if (a<dots)ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_2,period/2+sintable[a]*modu/256); else ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_2,period/2-sintable[a-dots]*modu/256); a=a+dots*2/3; if (a>=2*dots) a-=2*dots; if (a<dots)ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_6,period/2+sintable[a]*modu/256); else ROM_PWMPulseWidthSet(PWM1_BASE, PWM_OUT_6,period/2-sintable[a-dots]*modu/256); ROM_PWMSyncUpdate(PWM1_BASE,PWM_GEN_0_BIT |PWM_GEN_1_BIT|PWM_GEN_3_BIT); switch(irqcount%10){ case 0: temperature=(temperature*127+analogRead(26))/128; break; case 1: voltage=(voltage*31+analogRead(27)*3)/32; break; case 2: current=(current*127+analogRead(25)*8)/128; break; case 3: poti=(poti*127+analogRead(28)*8)/128; break; } } void oh_shit(void) { //in case of severe overcurrent we shut down! ROM_PWMFaultIntClearExt(PWM1_BASE,PWM_INT_FAULT0); ROM_PWMOutputState(PWM1_BASE, PWM_OUT_0_BIT | PWM_OUT_1_BIT | PWM1_BASE | PWM_OUT_2_BIT | PWM_OUT_3_BIT |PWM_OUT_6_BIT | PWM_OUT_7_BIT, false); }  

  4. Like
    PTB reacted to RobG in MSP430 Nixie Clock   
    MSP430 based Nixie tube clock.

    I was looking for some nice Nixie tube digit images so I could add them to my EduKit library, but I couldn't find any usable ones. I decided to just buy few of them and photograph myself. Then I thought that it would be a horrible waste if they just sit in a drawer. So here it is, my first Nixie project since... 1987.
    This clock will be available as kit, but since this is v1, I will most likely make some adjustments.
    Any suggestions are welcome.

  5. Like
    PTB reacted to Fred in ESI Project: Laser coolant monitor   
    My TS430PZ100D target board arrived today. All seems to work OK with the older FET430-UIF. I used to wonder with those ZIF sockets were so expensive but having seen one up close it seems a little more reasonable. Some tips if you're also using one:
     You press down to open the ZIF socket, drop the IC in and the let it spring up to grip.  If you've not worked up close with LQFP before, the pin 1 marker is the smaller one in the bottom left, so this lines up with the arrow on the ZIF socket. Text is printed in different orientations on everything so ignore that completely. Also ignore the two larger circles on the IC.  
    I'm still waiting on the other components I need, so I just fired up blinky to test everything was working. If you look at the CCS generated blinky code it includes a line to disable the default GPIO high impedence mode. I would probably have been caught out by this if I hadn't been so lazy I couldn't write my own blinky code!
    I would play a little more but I'm just off to finish laser cutting some stuff for @@PTB from that PoTM contest way back in March.
  6. Like
    PTB reacted to cubeberg in 43oh badge   
    Sorry this took so long -  but badges are finally up on tindie!  
  7. Like
    PTB reacted to sq7bti in Newtonian/Dobsonian telescope controller   

    A summary of changes:
    instead of unipolar motor drivers, now I used a bipolar drivers very popular in RepRap projects, here A4988 (or DRV8825) 28byj-48 modified for bipolar cheap HC-05 for bluetooth SPP GPS module U-blox NEO-6m added RTC DS1307 to provide date/time reference even in the first seconds after power-on and 56 of NVRAM bytes added (optional) humidity and temperature sensor DSTH01 added a I2C socket to connect external temperature sensors to provide information about motors temperatures added PCF8574 for microstepping configuration of A4988 drivers added buzzer for audible indication added output for 12Vdc fan of main mirror - PWM controlled Nokia 5110 display replaced with a red back-light
    As the software is concerned, there were several improvements as well. The most important is that the motors are now driven by an interrupt driven AccelStepper

    With kind regards,
  8. Like
    PTB reacted to Thorvard in CC3200 LaunchPad Discussion   
    Good news everyone, its working again
    After running the 'getting_started_with_ap' example from the cc3200 SDK i was able to put the device into smartconfig mode and connected it to my router, i had to use the iOS App because the Java Webbrowser code that Ti supplied wasnt working.
    But the problem with flashing still existed, so after wasting another few hours i came to the conclusion to format the flash using the Uniflash Tool, despite the fact that the Uniflash manual does not recommend it. But hey, the Launchpad wasnt flashing correctly, i had nothing to lose
    After formatting it to 1MB flash, NO checkmark at security or alert option, i was able to flash the OOB Demo successfully without error.
    Why is the TI stuff (CCS, Uniflash) always so complicated?
    I can't wait for Energia supporting this Launchpad, i love   Energia for being so uncomplicated, because im still a beginner   to embedded stuff
  9. Like
    PTB reacted to chicken in Displaying .c Images Using Energia Sharp LCD BoosterPack Library   
    Here you go @@Hassanul, I added a simple method to my Energia library that allows to display images like the TI logo.
    // display TI logo for 2 seconds display.bitmap(pixel_ti_logo, 96, 96, 0); delay(2000);
    and yes, my SHARP display is literally catching dust []
  10. Like
    PTB reacted to cubeberg in 43oh badge   
    This project was a collaboration with Texas Instruments.  I've kept it hush-hush so far, but as of yesterday - it's finally out in the wild!  Yesterday at the SF Maker Faire, Texas Instruments started giving away boards at their booth.  If you're visiting the Maker Faire today - please drop by booth 220!
    Thanks a ton to TI for sponsoring and feedback on the design.  Will Cooper, Adrian Fernandez, Mark Easley, Dung Dang and Rachel Platis were all involved - this wouldn't have happened without them.
    Also - Elecrow did a wonderful job on the boards and initial kitting (I added the batteries and MCU once back in the US).  
    Badge page on 43oh - http://43oh.com/badge/  (drop by this page for more info and an intro video).
    Github with schematics, sample code, etc. : https://github.com/dd430/430RocketBadge
    The board is intended to be easy to solder - parts were kept to a minimum.  It showcases several features of the MSP430G line.  The board has a Cap Touch slider as well as 5 LEDs.  The pre-programmed demo starts in a POV mode.  If you swing the badge in a circle, you'll see the pre-programmed messages written in the air.  My favorite part of the project though - has to be the ability to update the message on the badge via the light sensors on the board.  You may have seen similar projects.  One sensor is used for the clock, another for the data.  A simple web page allows design of a message and then uses two squares on the page to trigger high/low values on the light sensors.  You can find it at the 43oh badge page above.
    All in all - we were able to get 500 kits created.  Hopefully these will be given away at events that TI is attending for quite a while.  I'll post back if I hear they're going to show up for an event.  Hopefully we'll also have a few to give away to forum members as well.  
    BTW - I will say - creating 500 kits of something is a significantly different endeavor than just a handful
    Boards after manufacture:

    500 kits arrived at my house:

    I started with several ideas for the board initially - but we ultimately ended with the POV design.  V1 of the design used a shift register to control the LEDs and took significantly longer to solder.  Not the best for a beginner kit  Not to mention getting the clock working with the shift register was a bit squirly for some reason.
    V1 badge vs V2

  11. Like
    PTB got a reaction from GeekDoc in 2.2" Color LCD Booster Pack with Touch   
    if (z>TOUCH_TRIM) { // x0 = check(x0, 311, 1632);//Old Style Screens from RobG (Green PCB) // y0 = check(y0, 195, 1859);//Old Style Screens from RobG (Green PCB) // // x = map(x0, 311, 1632, 0, LCD_WIDTH);//Old Style Screens from RobG (Green PCB) // y = map(y0, 195, 1859, LCD_HEIGHT, 0);//Old Style Screens from RobG (Green PCB) x0 = check(x0, 156, 1874); //Edited by PTB New Style Screens from RobG (Red PCB) y0 = check(y0, 120, 1859); //Edited by PTB New Style Screens from RobG (Red PCB) x = map(x0, 156, 1874, 0, LCD_WIDTH); //Edited by PTB New Style Screens from RobG (Red PCB) y = map(y0, 120, 1859, 0, LCD_HEIGHT); //Edited by PTB New Style Screens from RobG (Red PCB) return true; } else { return false; } } Here's the 4 lines of code change (to the old code) at the bottom of LCD_Touch.cpp I did to get touch working for me on the newer screens
  12. Like
    PTB got a reaction from GeekDoc in 2.2" Color LCD Booster Pack with Touch   
    The earlier versions of Robs board have the opposite direction for the touch panel.
    I had to change some code to flip the y direction and tweak the calibration.
    The old code works great with the old screens.
    But the new screens need a few lines changed.
    I'll dig out what i did just to throw it into the mix.
    These are fantastic boosterpacks. Absolutely love 'em.
  13. Like
    PTB reacted to StupidPig in Yet another DIY reflow oven implementation   
    After using a hot air station for my smd work for about two years, I think it is time to upgrade my tools to increase my productivity, so I'm looking for adding a reflow oven to my workbench. I searched the web and found many threads about DIY reflow oven, and there are a couple kits looks pretty neat, but somehow all the kits are no longer available for purchase, so I just have to make my own.
    First is the oven. I brought a cheap one from Amazon. Well, it's cheap, but already better than the one I has in my kitchen.

    Then I start working on the controller. Originally I was planning to use Nokia 5110 LCD for the display, but just when I'm going to start the project, I received an email from the store stating that RobG's 2.2" Touch LCD is back in stock! What a prefect timing! So, my controller end up using a MSP430G2553 + RobG's 2.2" touch LCD.

    The board under the LCD is just simple contains the socket for the 2553, a 3.3v regulator, and headers for the LCD, relay, and thermocouple sensor breakout board. The power input is via a mini USB port, and there is also a NPN transistor to power the SSR relay using 5V instead of 3.3V, as I think I read from the web that the SSR i brought form ebay is not quite working with 3.3V trigger.
    The thermocouple breakout board is using MAX31855, brought from Adafruit. I brought the type K thermocouple from them too.

    Time to put everything together. the front panel of the oven control, the temperature selection knob, and the mode selection knob is removed. I keep the bottom timer knob and use it as the main power switch. The SSR is mounted onto a big heatsink, then put on the bottom of the oven. A hole is drilled to route the thermocouple into the oven chamber. A cheap USB charger is also put inside the oven to used as the power supply, but the temperature keep reporting error occasionally when using that charger, so it end up goes to the rubbish bin. No more error when I use my LG phone charger.


    I did my first run and so far looks good. The controller right now just sit on top of the oven, and I'll need to comes up with a way to mount it on the front of the oven panel area.

  14. Like
    PTB reacted to StupidPig in 2.2" Color LCD Booster Pack with Touch   
    @@PTB, Yeah this screen is great. It is strange that I just use the same (195,1859) range as the original lib y axis range for the x axis, and it works great, let me try the (156,1874) range tonight. And I think I just take it one step further by supporting the touch with all 4 screen orientation.
    BTW, here is what I used the screen with...... So many threads about making the MSP430 reflow oven kit, but almost none of them available for purchase, so I just got to make my own.

  15. Like
    PTB got a reaction from RobG in 2.2" Color LCD Booster Pack with Touch   
    if (z>TOUCH_TRIM) { // x0 = check(x0, 311, 1632);//Old Style Screens from RobG (Green PCB) // y0 = check(y0, 195, 1859);//Old Style Screens from RobG (Green PCB) // // x = map(x0, 311, 1632, 0, LCD_WIDTH);//Old Style Screens from RobG (Green PCB) // y = map(y0, 195, 1859, LCD_HEIGHT, 0);//Old Style Screens from RobG (Green PCB) x0 = check(x0, 156, 1874); //Edited by PTB New Style Screens from RobG (Red PCB) y0 = check(y0, 120, 1859); //Edited by PTB New Style Screens from RobG (Red PCB) x = map(x0, 156, 1874, 0, LCD_WIDTH); //Edited by PTB New Style Screens from RobG (Red PCB) y = map(y0, 120, 1859, 0, LCD_HEIGHT); //Edited by PTB New Style Screens from RobG (Red PCB) return true; } else { return false; } } Here's the 4 lines of code change (to the old code) at the bottom of LCD_Touch.cpp I did to get touch working for me on the newer screens
  16. Like
    PTB got a reaction from RobG in 2.2" Color LCD Booster Pack with Touch   
    The earlier versions of Robs board have the opposite direction for the touch panel.
    I had to change some code to flip the y direction and tweak the calibration.
    The old code works great with the old screens.
    But the new screens need a few lines changed.
    I'll dig out what i did just to throw it into the mix.
    These are fantastic boosterpacks. Absolutely love 'em.
  17. Like
    PTB reacted to Rei Vilo in Pin Names - Connected Launchpad   
    Welcome to Energia! 
    Energia release 12 supports the Connected LaunchPad. The way pins are numbered on Energia is PN_0 for pin PN0.
      Please find a pre-release of the pins map for the TM4C129 LaunchPad.   Update! Pins map with picture (Click to enlarge, full-sized picture)
  18. Like
    PTB reacted to bluehash in [Energia Library] Petit FatFS SD Card Library   
    In src/ff.h
    typedef enum {     FR_OK = 0,                /* (0) Succeeded */     FR_DISK_ERR,            /* (1) A hard error occurred in the low level disk I/O layer */     FR_INT_ERR,                /* (2) Assertion failed */     FR_NOT_READY,            /* (3) The physical drive cannot work */     FR_NO_FILE,                /* (4) Could not find the file */     FR_NO_PATH,                /* (5) Could not find the path */     FR_INVALID_NAME,        /* (6) The path name format is invalid */     FR_DENIED,                /* (7) Access denied due to prohibited access or directory full */     FR_EXIST,                /* (8) Access denied due to prohibited access */     FR_INVALID_OBJECT,        /* (9) The file/directory object is invalid */     FR_WRITE_PROTECTED,        /* (10) The physical drive is write protected */     FR_INVALID_DRIVE,        /* (11) The logical drive number is invalid */     FR_NOT_ENABLED,            /* (12) The volume has no work area */     FR_NO_FILESYSTEM,        /* (13) There is no valid FAT volume */     FR_MKFS_ABORTED,        /* (14) The f_mkfs() aborted due to any parameter error */     FR_TIMEOUT,                /* (15) Could not get a grant to access the volume within defined period */     FR_LOCKED,                /* (16) The operation is rejected according to the file sharing policy */     FR_NOT_ENOUGH_CORE,        /* (17) LFN working buffer could not be allocated */     FR_TOO_MANY_OPEN_FILES,    /* (18) Number of open files > _FS_SHARE */     FR_INVALID_PARAMETER    /* (19) Given parameter is invalid */ } FRESULT;
  19. Like
    PTB reacted to energia in New Energia release 0101E0012 - 03/20/2014   
    I am happy to announce that release 0101E0012 just went up on energia.nu. 
    I want to thank everybody for their support and contributions. Energia would not have been possible without such an awesome community!
    Details of the release can be found on http://energia.nu
  20. Like
    PTB reacted to jpnorair in Mailbag   
    I second the "take pics."
    As for removing it, all you need is a sharp knife, good tweezers, antiseptic, and some super glue (long story, and nothing to do with RFID).  On this note, I also recommend installing it into a part of your body easily accessible to your dominant hand.  Embedded engineers are accustomed to soldering tiny components.  Surgery is a walk in the park.  
  21. Like
    PTB reacted to sq7bti in Newtonian/Dobsonian telescope controller   
    Hello everyone,
    There is a couple of similar projects available on the internet. Some of them base on Arduino and PIC performs very basic mount control without math intensive computation implemented in embedded controller. I decided to build my own with the following goals:
    ease of use by an inexperienced amateur astronomer (full automatic operation) precision and resolution of position  last but not least: the price Final, or better say at the moment, design comprises of the following components:
    Stellaris LM4F launchpad central control unit, two ULN2003 unipolar stepper motor driver chips, two 28byj-48 stepper motors one moving in azimuth, and in elevation via gear train, communication module: Bluetooth serial module. It allows sending a coordinate set-point and provides position feedback to Stellarium, GPS module providing position and precise time reference - PPS gives 1us accuracy, Nokia 5110 display unit and joystick for standalone operation, now obsolete mouse (PS/2) modified to provide independent (incremental) position information Resolution that was reached is a single step of approx. 5". Given the size of Jupiter to range from 30" to 50", this positioning resolution makes the view comfortably stable in standard 60° FOV eyepiece at reasonably high magnification, without the need to adjust AZ/ALT continuously.
    During the development I made use of several opensource and projects available online, namely:
    AccelStepper for stepper control, TinyGPS++ for NMEA decoding, Arduino telescope controller was my inspiration and reference for Taki's matrix method for coordinates transformation, of course Energia as my IDE Upon power-up the mount is performing:
    homing acquisition of current location (longitude/latitude) and time via NMEA stream moves to 3 brightest (most convenient) stars in succession to perform 3 star alignment procedure - they are selected from the list of over 500 stars in built-in catalog (the  brightest are used for the alignment, tough), once aligned the mount is in tracking mode: it tracks the view to counter the apparent movement of objects in the sky, waiting, either for the user to move to particular object - selected from the library of stars and Messier objects, or awaits connection via Bluetooth from a PC running Stellarium with a plugin and slews to selected object. search for the object that should be visible in the eyepiece and display important information on LCD - I compiled in 500 brightest stars from HYGXYZ and full Messier catalog.  I have very little experience as amateur astronomer so far, so some of the objectives might have been not very obvious for me in the beginning. This project was also a good way to make use of my free time and gain experience in embedded system design.
    With kind regards,
  22. Like
    PTB reacted to Rei Vilo in [Energia Library] LCD_screen Library Suite   
    Please find a special release of the LCD_screen library for Rob's Color LCD Booster Pack (320x240 with microSD card socket) on Energia.
    The LCD_screen Library Suite has evolved with a more mature structure.

    It relies now on a core abstract base class (with pure virtual functions). Two classes are derived from the abstract base class with or without the graphic and text primitives depending on the kind of screens. Each screen uses one of the derived classes and only needs to redefine 4 functions Screen_ILI9340 - Reference Manual.pdf
  23. Like
    PTB reacted to username in MSP430 WiFi Smart Scale   
    Hey all,
    *Quick Reflow Oven Update
    Sorry you haven't heard much from me in awhile, work has been keeping me very busy. First off, I apologize for not being able to keep up with the reflow oven kit demand. My new job has been abit demanding and the displays I was using appeared to have gone off the market so it would require a redesign. In addition, I ran out of code size on the msp430 while many features still needed to be implemented. I'm working on a new one but it won't involve a msp430.
    *Onto the project
    So with my new job and all i've spent abit too much time sitting around. Consequently I needed a little motivator to get out to the gym. Basically I wanted to log my weight data and view it in a graphical form. Apparently these already exist in the form of a "smart scale". Anyhow, didn't really know that going into the project nor would I feel like paying 100USD+ for one.
    Step 1:
    First I bought the worlds crappiest weight scale at walmart for less than 20usd

    Step 2:
    Then I opened it up and attempted to hack the internal control board. Acourse it was one of those black blobs which meant it was a system on chip. Sadly the analog lines were feeding directly into the micro which presumably had its own differential amplifier. Sadly there were no outgoing lines from this micro that had a voltage or pulse width proportional to the weight. Long story short, there was no easy way to get the weight from the prebuilt electronics so I scraped it.

    Step 3:
    So next step was to determine how to build the electronics required for the weight scale. Weight scales use a sensor called a load cell which are generally just strain gauges. Strain gauges are sensors that have a very very very small change in resistance with respect to weight. Consequently, a wheat stone bridge configuration is generally used to read them. In addition, one uses multiple strain gauges in order to avoid temperature fluctuation and drift. This weight scale used load cells similar to ones on sparkfun:

    So in the scale, there are 4 load cells. Each load cell is a half wheat stone bridge. With clever wiring, you can make 1 wheat stone bridge consisting of 4 half wheat stone bridges, see picture below:

    Step 4:
    ...Time to go to work so i'll post more on this later. Basically I used a instrumentation op amp to read the Wheatstone bridge. Then I built a board with dorkbot pcb and populated it. As for the 802.11 support, ages ago I bought a wizfi210 from bluehash so I used that. Also used one of my few remaining 2.2" lcd displays.


    Step 5:
    write the code stuff and make it upload to xivley:
    Step 6: (ongoing)
    WIP is getting this to not drift and give consistant repeatable measurements.... i'm getting there.
    and yea.. i'm off to work. I'll get more of a writeup on this latter.
  24. Like
    PTB reacted to Automate in A new Tiva C LaunchPad about to be Announced!!!!!   
    More info released http://www.ti.com/ww/en/launchpad/launchpads-tivac-ek-tm4c1294xl.html#tabs
    $20 with Ethernet but not in stock yet
  25. Like
    PTB reacted to Rei Vilo in Sakoman microSD-Card BoosterPack Review   
    Please find a review of the microSD-Card BoosterPack from Sakoman and the pins map.

    Click to enlarge and download.

  • Create New...