Thursday, August 5, 2021

Tasmota standalone setup and flashing with python

I have:

   Sonoff - RF R2 

   Serial FTDI clone  (YP-05)   

   MaxOSx 10.10

   Arduino 1.8.8

Using Tasmota is the best and no need of any of these other crap. only issue is putting a header to the board for the initial flash

   Easiest way to plug the serial pins without soldering is using a header like here:  conectigng serial pins of Tasmota without soldering

Installing (Flashing Tasmota)

    Tasmota is the best firmware for sonoff to install, tried GUI tools none worked(atom, win tools etc)


    MacOS has perl & python by default so the tool that worked was esptool  which is a

python script, it needs pip so first download the pip installer

curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py

then run it (i ran both with sudo just to make sure)

python get-pip.py   

   Finally get the esptool with 

pip install esptool  

   


 Here it is ready to flash.. 1st let’s save the original firmware that came with it,

to find the port use Arduino IDE on ports it will list the new port from the FTDI adaptor

my esptool was not in the path I had to give full path hanging from my python dir in ~/Library/python

esptool.py -p /dev/cuxxx read_flash 0 0x100000 sonoff_orig.bin 
       
   and finally flashed it with

esptool.py -p /dev/cu.usbserial-xxxx  write_flash -fs 1MB -fm dout 0x0 sonoff_6.7.1.bin  
             

Tasmota picks up the time off  the net via NPT(by default npt.org) and boots with default values

time by detault is GMT time when initially connected to an AP with access to the net so the timezone needs to be updated


    Don't forget to put the sonoff in flashing mode i.e. unplug it hold down the only button and plug it in while holding down the button for a few seconds and it is ready to receive

  My customization

  I needed to use it remotely with no internet/router so when it starts it connects to a local AP(I use PDAnet on an old iPhone) then with webUI I can set the timers which stay when the unit is unplugged. But when no AP is available e.g. I leave the remote site to work standalone, by default when no internet Tasmota resets the timer (to 1970 actually the time 0 command is the default using time epoch stops using the NTP and keeps this time until powered off) that killed my needs and popped up with the setup site for 3 mins.  I had planned to add a checkbox on that screen from the setup that skips the NPT testing and popping the setup page when no internet and set up the Time to epoch but the source code was quite convoluted and a friend had an old router that  was much quicker than digging thru the code. Easy does it.

So I ended up using an old router and these settings

WifiConfig 5      (to wait when the AP in unavaiable)
timezone -5       (my timezone hours to GMT)
time xxx          (the current time from a call to epoch, will only take epoch after 2015)

     

  Hints

   Initial router was a wireless Huawei and it couldn't connect i.e. see the device 192.168.8.xxx I also had a NetGear Nighthawk where it did work as advertised on the standard channel (not the 5G) 



Also if you don't have a scanner to get the IP number  we can hard code it before hand

as below (keep in mind if swapping to a different AP the base address might be different and your hard coded IP needs to reflect that or it won't connect to the NTP server and hence the time will be set to 1970)

ipaddress1 [192.168.xxx.yyy]
restart 1

to point to a NTP server

ntpserver <ipadrress or host>

when switching APs it runs a restart


   If it becomes unreachable due to funny IP or similar reset it by holding the button for 4secs in my case it would not respond at all so I had to do a real "hard reset" manually since I was at the site with no serial port connection it goes like this: take power out for 30 secs then repeat a plug in for 10 secs and unplug it 6 times and on the 7th plugin leave it in an AP named sonoff-xxx will become available where the SSID can be set and from there it is easy to come back to life.


   



Thursday, December 31, 2020

Running other macos(newer) inside mac or hackintosh

It is a bit slow but sometimes you need some quick feature of a previous version of osx and having a virtual machine of that can quickly get you thru and be done with it. For instance in Yosemite I could run the EasyCapGrabber, it does not run on newer versions and of course I need to capture some old VHS tapes to digital.

If you search on the internet you will find quite a few pre-cooked Virtual Machines setup for VmWare but they are for the PC, well no biggie. Download the image of your choice and carry on. Make sure you also grab the admin pwd they usually state it in the site where you pull it down

Extract the files from the archive(usually a rar or a zip) there will a folder with the virtual machine
in a folder you'll find the .vmdk, .vmx, .vmxf, etc. which are for the PeeCee  all you need to do zip those files, then rename from .zip to vmwarevm and the machine is ready to go

Create a new VM in VMWare, make it of type macosx-64 bit it didn't matter it was an older previous version follow thru the basics when it asks for a HD select "existing" and point to the vmdk from above then go thru the standard setup and all is cool

Issues:
    The only issue I found is the common Networking connectivity that usually pops on most VMs, flipping from NAT to Bridged and backwards takes care of it sometimes with a reboot

   The one issue I had was when I was setting up Mojave on my trusty Mavericks(hackintosh on an E6420) all went well but the network wouldn't go. The issue was that my WiFi in my hackintosh sometimes goes bad and a reboot is needed(never got to fix it with command lines and didn't put a lot of effort on that) as a workaround I use the oldie Pdanet with some old iPhone and I'm good to go but sometimes the connectivity does not pass thru the VM, so a reboot and back to the regular WiFi and all is well. Also rebooting the VM under the pdanet connectivity on the host takes care of it so take your pick.

Friday, February 12, 2016

Midi(USB) with a CASIO SA-39 and Arduino (Clone)

Preface

There are a few posts on how to  make a MIDI keyboard out of a plain/toy keyboard, here I have my notes with a Casio SA-39. I made it with the plan of using it with a Mac (GarageBand) and to play with it in my band,  skipped the prehistoric MIDI interface and went straight to USB with the Arduino UNO as the little engine for this exercise. Got a set of the synth/organ sounds and it worked very good for keyboard sections when jamming/recording and didn't have to buy a MIDI keyboard. It also worked with my bro's hackintosh.

Required

   - Arduino Uno CH340G
   - MacBook 10.9.5 or higher
   - 74HC595 shift register
   - Basic Lab equipment(Multimeter, cables,etc)

The keyboard matrix

This was a little pain but got the mapping as below

and the actual layout of the keys and the ribbon cable. So an 8x4 keyboard
we'll read the 4 groups and find the key by outputting a mask.





   The revised  shift register interface for the casio, that is all is needed the Arduino UNO has the AVR chipset as USB interface which can be flashed to behave as a HIDMIDI from there the USB gets the serial MIDI and plugged to our Mac is good to go.

Actually I ended up going the much easier way using the free hairless-midi software and the cheap Arduino clone, read below.




Got the power(5V) from the USB and it works so it is truely just plug the USB keyboard and jam.






The Arduino interface


   - Borrowed an oldie Leonardo Uno to get started, as my el cheapo chinese Arduino Uno CH340G would get to me from Ebay, the Leonardo does not have the second AVR chipset but it was good start to double check the keymaps ... on the cheap Arduino needed to tweak the USB interface to make it work with their driver but it worked on the Mac
For the Casio matrix it required inverted masks and pull resistors to Vcc, the basic idea remains e.g. send an 8-bit mask and read the 4-pin group  for a LOW value to sense a key pressed.

  The code

My modded code is listed after a few debugging session this is the code




// Midi standard at 41 is the map to the casio-39 

/*
 * 
 *   Send out a mask and with the keybpard matrix check if that mask produces a key pressed loop thru the set and good 2 go
 * 
 *  Optimized the code to KISS it mode --  Becker Cuéllar 
 * 
 *    Send  out a byte(mask) and read IN 4 pins and mapp properly, the 74595 allows so only use 3 pins for the 3-octaves
 */

const int LED_pin =13;

// The 74HC595 uses a serial communication 
// link which has three pins
const int clock_pin = 9;
const int latch_pin = 10;
const int data_pin = 11;

// Pin Definitions

const int row0 = 8;
const int row1 = 7;
const int row2 = 6;
const int row3 = 5;

    int groupValue0 = 1;
    int groupValue1 = 1;
    int groupValue2 = 1;
    int groupValue3 = 1;



const int BASE_MIDI=41;   // (F on octave-0)

boolean keyPressed[32];
boolean keyPressedPrev[32];
int noteVelocity = 127;
int curKeyCmd, curMIDIKey;

// proper mask for my board
int cur_byte_mask[] = { B11111110, B11111101, B11111011, B11110111, B11101111, B11011111, B10111111, B01111111 };




void setup() {
 
  // set up diode for visual output
  pinMode(LED_pin, OUTPUT);

 // set pins for the move
  pinMode(data_pin, OUTPUT);
  pinMode(clock_pin, OUTPUT);
  pinMode(latch_pin, OUTPUT);

  pinMode(row0, INPUT);
  pinMode(row1, INPUT);
  pinMode(row2, INPUT);
  pinMode(row3, INPUT);

  for (int j=0; j<32;j++)
  {
     keyPressed[j]=false;
     keyPressedPrev[j]=false;
  }
      
  Serial.begin(31250);   // MIDI standard needs this rate
  Serial.begin(115200);   //best to cover older macOS as they have issues for lower rates 
delay(1000); // time to cool down at startup } // --- end of setup --- void loop() { for (int col = 0; col < 8; col++) { // shift scan mask to following column scanColumn(cur_byte_mask[col]); // check if any keys were pressed - rows will have HIGH output when nothing pressed groupValue0 = digitalRead(row0); groupValue1 = digitalRead(row1); groupValue2 = digitalRead(row2); groupValue3 = digitalRead(row3); // since it is an inverted mask is with a '0' scanning a '1' is keyPressed[col]= ( (groupValue0==0) && ( (two_exp_n(col)&cur_byte_mask[col]) == 0) ); handleSingleKey(col); keyPressed[col+8]= ( (groupValue1==0) && ( (two_exp_n(col)&cur_byte_mask[col]) == 0) ); handleSingleKey(col+8); keyPressed[col+16]= ( (groupValue2==0) && ( (two_exp_n(col)&cur_byte_mask[col]) == 0) ); handleSingleKey(col+16); keyPressed[col+24]= ( (groupValue3==0) && ( (two_exp_n(col)&cur_byte_mask[col]) == 0) ); handleSingleKey(col+24); }// for } // -- end of loop --- //find which bit has a '0' in this mask - arduino exp didn't work 4 me int two_exp_n(int this_n_exp) { int ret = 1; int i=0; for(int k=0; k<this_n_exp; k++) ret = ret*2; return(ret); } // --- end of bit_pos --- // status byte 0x1001 CCCC -) status byte(1st bit=1) note=ON on channel CCCC // followd by optional data bytes 0PPP PPPP 0VVV VVVV pitch(actual music keu lije a C) and velocity // // 0x90 Note ON on channel 1 // 0x80 Note OFF on channel 1 // void handleSingleKey(int thisIdx) { if( keyPressed[thisIdx] != keyPressedPrev[thisIdx]) { curKeyCmd = keyPressed[thisIdx] ? 0x90 : 0x80; noteOn(curKeyCmd, BASE_MIDI + thisIdx , 127); keyPressedPrev[thisIdx] = keyPressed[thisIdx]; } } // --- end of handleSingleKey --- // ---- my routines to handle the stuff // 74HC595 shift to next column void scanColumn(int value) { digitalWrite(latch_pin, LOW); //Pulls the chips latch_pin low shiftOut(data_pin, clock_pin, MSBFIRST, value); //Shifts out the 8 bits to the shift register digitalWrite(latch_pin, HIGH); //Pulls the latch_pin high displaying the data_pin } // // Midi msg: [cmd] [data1] [data2] // // basic midi: cmd = 100K cccc (cccc is the channel 0-based) , K=1 note ON , K=0 note OFF // data1 = 0ppp pppp (the pitch 0-127) , middle C is 60 // data2 = 0vvv vvvv (velocity 0-127 or haw hard is pressed) // void noteOn(int cmd, int pitch, int velocity) // make MID message , velocity specifies haw hard was the key pressed(0-127) { Serial.write(cmd); Serial.write(pitch); Serial.write(velocity); } }



 Flashing Arduino to HID MIDI


The cheap Chinese Arduino clones are not flashable so for this a real one is needed. Also it is painful when you need to touch up the Arduino software when you want to add a new feature or correct a bug the whole process has to be rolled back and debugging is painful.


Using a MIDI-USB adaptor 

Next try was just use one of those MIDI to USB interfaces, quite straightforward pull the Arduino Tx line  with a 220-Ohm resistor to the MIDI IN, got a set from Ebay but they are temperamental, they do work but after you unplug it it gets a bit cumbersome to get it back and also is more wiring/bulk.

 Best solution! with software no need for flashing AVR and can use the clones.


 I'm doing this for the Mac(GarageBand, Logic Pro, etc.) 


The best solution and I'm kinda of staying there is using  hairless-midi software (free) which maps the virtual serial port of your Arduino to the MIDI via software on the mac and works flawlessly with the Arduino clone so it is the cheapest solution,  I can pull it out put it back and just restarting the hairless software gets me back to MIDI and ready to jam. Just need to make sure you close it before loading a new software version with the Arduino loader as obviously they use the same virtual serial port and only one can have it.



.


When you start probably you do not have an IAC driver listed on the MIDI out dropdown so setup one this is all well known but just in case:
    - Open Audio MIDI SetpUp  app
    - Click Window>Show MIDI window
    - Highlight IAC and Show  Info,  here check device is on line and ports are defined

Only issue I have found is the driver for the Arduino clone has to be right to get it to work nicely(CH340 dated 12/25/13 worked good for mine)also the rate that works better on older versions of the macOS(tried snow Leopard thru Mavericks) is 115200 on the Arduino code



Thursday, November 12, 2015

Bypass iCloudLock on iPhone4 Verizon 7.1.2 (on a Mac)

Preface

I got this Verizon iPhone4 from Craigslist, the guy of course told me the iPhone had clean ESN and it he cleared it from iTunes so I could activate it. That was not true, a few emails he claimed he cleared it and then he disappeared  so there I was stuck with an iCloudLocked iPhone completely useless.
Searching about it there seem to be a way to bypass the iCloudLock, some said use these IP's on iTunes by all of those never worked, others said just JailBreak it but it wouldn't take that either, then some said there is a way to bypass but only works on iPhone4, using the ssh_rd.jar method and after quite a few tries that worked for me on the Mac.

Required

   - Hacktivate Tool for iPhone4 (win only version once installed  find the ssh_rd_rev04b.jar file and move it to the Mac. They keep moving/hiding this file around so you have to dig for it. In a couple of days I'll place a copy in my web site if you cannot find it.
   - Make sure your Mac has Java installed mine had JDK1.8,  my Mac is on Mavericks 10.9.5
   - You need to have net access

The tries

The Hacktivate Tool for iPhone4 : in a few words this tool injects stuff that allows to access the area where the initial setup is located, which is just a Setup.app that gets launched when you need to do the initial setup of the locked iphone if you can delete this Setup.app it won't show its nasty face and you can start using the iPhone as when it was new without a lock


 Tried the exe it on a VM on my Mac  but it never worked for me as it wouldn't get too far, then I found another post with the similar idea but from the command line they had a newer ssh_rd.jar and manual set of instructions, I tried that one several times but it'll fail but it gave me the plan of attack and I went that way.



 Steps for the working method


   - After many tries on the manual method it was obvious this could be done on a Mac pure command line no funny GUI or tools, as the manual method wouldn't complete I dag into the Hactkivate tool(Win version) and found an earlier ssh_rd_rev04.jar file there pulled it from the VM to the Mac.

   - Open a Terminal and run it like this of course being in the same folder where the jar file is. Need to put the iPhone into DFU mode.
java -jar ssh_rd*.jar
 It goes thru a whole bunch of downloading this, patching this ... until it gets done and it asks to SSH to the iPhone

   - Open another Terminal and SSH using the built-in ssh from the Mac like this, using the alpine password

ssh root@127.0.0.1 -p 2022

 -  The ssh_rd tool did its pirouette and leaves the iPhone ready to get into the area where the Setup.app is, deleting this app is all we need to go straight to the iPhone as when there was no lock. Once you SSH successfully in do the cmds below

cd /mnt1
mount.sh
ls  (you'll see the Setup.app here)
rm -rf Setup.app


   This leaves the iPhone in Recovery mode, just get out of it ,  reboot and Voila!! there it is you can slide and get into the iPhone now.

 Easy as Pie ;-)

Saturday, November 7, 2015

Yosemite on Dell Latitude E6420

Preface

I tried to use the Clover method but kept on getting the kernel panic IntelCPUPowerManagemnt so that obviously was not gonna do it for me so then I tried the Chameleon and it did go a bit better

E6420 Specs


 Dell Latitude E6420, i5 2.5 GHz  (i5-2520M aka sandy bridge) , 4GB 667MHz DDR3,   Bios A21
 SATA 320GB  WD3200BEKT
 NVIDIA 4200M
 Broadcom Wifi BCM5880

 What I needed


   - 8G USB memory stick
   - USB mouse & Keyboard (just in case)
   - Yosemite Install app
   - Bootpack E6220 from here and E6420Yosemite.zip from Clover
   - A little bit of patience and perseverance

 The process

  The Clover method never worked for me no matter what ssdt, overwriting with the NullPowerMgmt, etc it would always pop with the KP IntelCPUPowerManagement, the Chameleon method was my choice as I've done a few already so I'm more familiar with it.

 I made the USB using the OSxLatitude method here but there is no bootpack for the E6420 at time of this writing, there is a Exx20 bootpack there but that one could not rebuild an SSDT for my CPU i5-2520M it complained about my board-id not being right or something and I got left with nowhere to go. I seemed to have read the E6220 is close so  I downloaded that, and also I had the E6420Yosemite.zip from the Clover method handy. Not sure if needed but I copied the kexts from the E6420Yosemite/Clover/kexts/10.10  to the Extra/Extensions of the E6220 bootpack

I started with un unformatted drive and no matter what I did to the USB it wouldn't boot from the USB, I had to install win7 and then it would boot not sure if there is a better trick for this, but that is how I got around that.

Shot 1: made the USB and just used the  Extras from the bootpack from E6220 got a lot deeper than Clover but it'd show the progress bar under the logo and the cursor would come up and then the turn into a beachball and stayed there I even left it overnight and nothing

Shot 2: I added kexts from the E6420Yosemite.zip to the Extra/extension extension in the USB , ran the kextwizard to make sure the SLE and all permission are correct and again as before it get up to beachball and stuck there,  hit the wall hard again then found these are the flags to get thru that
-v kext-dev-mode=1 dart=0
and it did get thru it got me to the starting install ... it asked for wireless PAD  the space bar skips it and it installs fine. Of course I reformatted the HD. It comes up, installed Chameleon to the HD and copied Extra from usb to root of HD, all good no wifi, nor battery status. But the rest is all good. 

  Updated to 10.10.1 from apple it had issues booting, booted thru USB and copy back Extra to root of HD and reinstall the kexts to SLE using kextwizard and all good. 

  Wifi still would not work ordered BCM4322 which is supposed to work. Got the wifi card but upon further reading it was found out the one that works is the Atheros AR9281 so that pushed me into getting a dual boot with Mavericks


Dual Boot with Mavericks

   I was about to order a SSD and use a  caddle adaptor to make a dual boot,  but a 320GB become available and since on Mavericks everything would work I went with a Mavericks install as I had the steps worked out on my Mavericks on a D630  just added the missing pieces for a E6420 to the USB
 to keep it simple I pulled the HD with Yosemite and place the other HD there and carried on with the Mavericks install, a few tweaks and everything worked including the wifi.(BCM4322)

  Finally I place the Yosemite as the main HD and the Mavericks as the secondary HD via caddle but for some reason after chooosing the Mavericks from the chameleon booter it would get stuck at the plist there seems to be a fix for this but my attempt didn't work , booting from the USB and choosing the proper drive worked with the flags -v -f GraphicsEnabler=No did it so that was good enough I use Yosemite for some Apps that require that and Mavericks as my main HD I swapped the HD's and it is all good.


Mavericks boot to Blank screen kink

   So when working as a Mavericks it was great but here and there it would boot to a blank screen, e.g. it would go thru the whole booting screen and when it should show the login it would go blank
then it would vary but trying it over and over eventually it would boot, of course this is not efficient and a couple of times it bit me hard as it was my main machine and had an important work web meeting I missed due to this as the bloody box would boot to the blank screen only after hours trying it did boot.

    Fix 1: Run the KextWizard and run Maintenance checking the Extra and the SLE after this it would always boot normally, I found out after running compilers like XCode/Eclipse or similar it'd made it more prone to the blank screen.

    Fix 2: When the machine would freeze hard it'd need a hard reset and of course Fix1 cannot be run so this one got me thru: Boot with the following switches -v -f GraphicsEnabler=No IGPEnabler=No nv_disable=1 this would boot in a lower resolution and not the pesky blank screen here the kextwizard from Fix1 can be run and back in business

   Fix 3: The Fix1 works here/there but the real reason is that there is a kext that got unnecessary entries in its plist
/S*/L*/E*/AppleGraphicsControl.kext/C*/P*/AppleGraphicsDevicePolicy.kext/C*/Info.plist

The section should be only like this

<key>ConfigMap</key>
<dict>
    <key>Mac-F60DEB81FF30ACF6</key>
    <string>none</string>
</dict>

mod'ed it rebuilt it by running the commands below, and it no more black screen.
sudo kextcache -system-prelinked-kernel
sudo kextcache -system-cache

 Fix 4: I still use Mavericks at the time of this update and still get it, seems to be something to live with as it usually pops when it is not shutdown properly or after a heavy CPU use and/or randomly.  A couple of extra things that helped: 
   - Leave it unplugged overnight and without the battery
   - Before shutting down take it in/out of sleep mode several times 
   - It seem to be the nvram needs to be reset so one quick variation is unplug the laptop,pull the battery out and press the power button for 30seconds or more and voila!!!

At the end of the day it seems like the NVDIA video card somehow gets into a setting that when you boot back it cannot handle, when it works that setting seems proper, taking the battery out worked good so maybe is something that lives on the card when powered. In my case with a proper default high resolution with the -nv_disable=1 it always works and only need the full video mode when working with videos.


Other issues while running

Basic issues happened but this was a solid one,

   Invalid Sibling Links
    This was a tough one  when I had VMWare running and it would take a long time to close, just powered off the machine, next time it wouldn't boot as I had dual-boot just kept using the one that worked, but a few days later I needed the version in the drive with the issue, tried the basics like boot in single user mode run the fsck_hfs but nothing all would lead to the Invalid Siblings and/or B-tree error, they were suggesting grab what I could and reformat.Obviously that is the last thing to try. Someone suggested to run DiskWarrior, I had an older copy so I ran it from the good disk, it wouldn't run because I had some stuff linked to the disk with the problem.

    ps -aux |grep [Volume Name]

 pulled the list of processes to kill and Diskwarrior ran and it found a lot of stuff wrong especially from the VMware, so that looked good, but in the list some message came up with the message Serial Not longer valid and the button to apply the fix was grayed outI needed this right away and didn't have my credit card handy to buy it, I pulled down one of those hacks serial keys, tried it but the same at the end it'd say Serial Invalid, my last tried worked rebooted with no WiFi and set the date back a couple of years as that was the age of my old copy plugged the code by the tool and it ran and back to life. The DiskWarrior was a life saver.


Upgrade the Yosemite to Sierra

  Supposedly you download the installer from the Apple Store, run it,  fix the Voodoo and you are back in business, so I started it, after I ran the InstallSierra.app  I reinstall the proper Voodoo but then when I booted up nothing happened, later found out this is due to the fact I'm using the Chameleon method and this requires to install from the USB. There is a tool called createinstallmedia which creates a bootable USB from the Installer app, tried that but still no cigar.


  So for my Chameleon setup I need to make a USB just like it was done for Yosemite, I started that and used the InstallESD.dmg from the InstallSierra.app but later I found out I need to go the Clover way from the scratch. Sierra can be installed with the Chameleon method but I tried to go Clover to see if all of this Clover talk is for real(it is but not for this E6420 which has UEFI and NVDIA issues)  the closest I've got was installed everything but  when the USB would boot it'll come up with the Clover menu but empty.

Experiment From Chameleon to Clover 

Lots of people recommend to go the Clover way as supposedly upgrading the OS is almost as easy as doing it on a real Mac. So I experimented going from an installed Chameleon to Clover, actually it was straightforward. I started with a new HD where I installed my old Mavericks/Chameleon set and then swapped the booter to Clover, all I had to do was  rename the /Extra  and boot on the root , install Clover and play with the files in the EFI folder I get the Clover boot menu and boot to the Mavericks installed with Chameleon. Some issues with the keyboard/padtrack but that is easy to fix.

Then I tried to upgrade to Sierra from there, but there were issues as the OSInstallSierra keeps booting back to the same Clover menu or I was getting to the apple logo and progressing to 100% and staying there forever.

Finally Sierra  with Enoch(Chameleon) 

Cleaned the drive where I was experimenting with Clover, which creates an EFI folder deleted all files inside. Also deleted the recovery partition created by my trials with Clover with diskutil.

 Used this guide step by step and it got me thru, skipped the format of the drive since I wanted to keep my file on the HDD, after an initial boot, there was no wifi, no sound and trackpad too slow and it will only boot from the USB when used as a 2nd hard drive. I have the  old trusty Pdanet so the net is alive, run the KextUtility a couple of times and sounds works. Only issue I have left is the trackpad being too slow. Runing in regular resolution without the nv_disable=1 flag gets it good, trackpad is fine and no flickering on screen

Sierra is the end of the line for the NV4200M i.e. high res display, high sierra can be ran in low res i.e. with nv_disable=1. when I boot this Sierra in high res it is all fine but the sleep kicks in too quick, just make sure you turn the sleep to never
 
WiFi was a bit unstable it will work for a bit then turn off and couldn't be turned back on, played with BCM kexts, still about the same, installed IO80211HighSierra.kext and so far wifi holds good


All in all a usable drive if I need to boot here, I have installed VMWare versions of High Sierra and Mojave and the VM comes up fine with Yosemite/Mavericks a bit slow  but enough to do my Xcode Angular dev tasks.






Tuesday, September 9, 2014

CyanoGenMod 10.1 (Android 4.2.2)in Galaxy S SGH-T959V

Preface

I promised my brother I could upgrade his old Galaxy S from 2.3.x  so he's up to speed. The CNM site states the ROM they have there does not apply to the T959V, but sourceforge to the rescue they have a ROM that fits this device, here are the steps I went thru to get it done.

The instructions


 Sourceforge does not have the steps so I went to the wiki cyanogenmod for GalaxyS and tweaked their steps of course this requires a bit of patience and trial and error. In escense we have to load first a recovery image to the firmware and then load the ROM above

 Before Loading the ROM


   - Followed the instructions, I carried those in a Mac, the first issue the heimdall would not run on Lion(10.7.x) so I had to use a Mountain Lion(10.8.x)
   - So now that works then the small image Semaphore_2.7.4.tar would not download from the links in the instructions so googled around and found it somewhere else.
   - Could not get the device to go into download mode tried all of those press Vol Down+Home+Power to no avail so I managed to get it with the command below, of course you do need adb on your Mac, if it is not in your path put the whole path for adb

sudo adb reboot download

   - Next hurdle it would not load the zImage (which comes out extracting it from the Semaphore file)
got a wrong protocol, kernel not a valid option and more lovely error messages, the way to go was put kernel in upper case


sudo heimdall flash --KERNEL zImage --no-reboot


  So the prerequisite is done.

 Loading the ROM

  The final step also had some glitches, putting the device into recovery mode can be done asily with VolUp+ VolDown+Power shows the moded recovery screen, but the sd card card got erased with a couple of folders  with  /sdcard being one of those folders, so turn it off and copy over the ROM(zip file) in the sdcard folder and just to be safe rename it to update.zip, now reloading it in recover mode allows to scroll for the file and it starts to load the ROM, some little warning pops but it continues and eventually the CyanoGenMod logo pops it takes a little while but in the end 4.2 comes up and job done.

Also don't forget to download gapps from CyanoGenMod for the 4.2. so that basic Apps are there when rebooting.


One caveat

  After a failed trial it wouldn't load the small image anymore, the way around was put in recovery mode and do wipe data/factory reset and set the USB debugging ON then another trial could be carried out.

Monday, April 7, 2014

ML10.8.4 on Optiplex 745

Preface

I did install SL on the Optiplex745 using myHack it was a breeze but needed the Mountain Lion I had the problem most people had no matter what I tried the installer wouldn't see the HDD so as usually I tried an unorthodox approach and it worked!

Dell Optiplex 745 Specs


 Dell Optiplex 745 mini tower, 2.13 GHz Intel core 2 duo, 2GB 667MHz DDR,   Bios 2.66
  SATA 160GB ST3160827AS dual partitioned with  NTFS and hfs+ partitions.
 DVI graphics card

 What I needed


   - SATA to USB adaptor to make a HD a USB drive
   - myHack 3.3.1
   - Files from osx86 http://wiki.osx86project.org/wiki/index.php/HCL_10.8.0/Desktops
only needed BCM7522D and patched IOATAFamily kexts for a post install
   - Mountain Lion as it is not available on Apple store I got 10.8.4 from a torrent
   - Another working mac or hackintosh (I have a D430/Lion which has been working really good)with       the  kextwizard app  to load kexts and fix permissions
   - A little bit of patience and perseverance

 The process

 I made the USB using myHack 3.3.1 , but no matter what I tried it wouldn't see the HD to install
only the USB, was about to redo and go the Unibeast way when I saw somebody stating he managed to install it but putting the HD as a USB drive, I tried it , made sure the BIOS was set without any HDD  and it did see the HDD and the installer started but it got stuck half the way, here is where patience pays,  Tried a couple of times same result sometimes Darwin wouldn't even boot, trick was power off and unplug it from the power then it would at least get stuck half the way. It was worth continuing this way, added &nbsp IOATAFamily to the E/E on the installer USB and AHCI_Extended_injector to S/L/E,  a couple of shots and it did completed the installation up to the 1st boot and initial setup. 


   Then put the HD back as a regular HDD and the bootloader came up but got the infamous waiting on root, a few shots and the same, so put the HD back as a USB and from another working Hackintosh installed the BCM7522D network kext  and the IOATAFamily kexts  too S/L/E on the installed partition recommended to get rid of the waiting on root, and it did go. For me this is good enough there are more extra kexts they recommend but I can get some work done with this and so far so good is been almost rock solid a few stuck on boot, the power completely off unplugging it takes care of that.

Final thoughts

  It was a typical install with quite a few retries  as usual but in the end it works good. Got the Eclipse/Xcode already working well on this box.